Forked from rsantosdev/docker-compose-sql-healthcheck
Created
August 30, 2023 17:48
-
-
Save Paula2001/9cc575d46833f24a53c22b80135e2b54 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.4' | |
services: | |
sql.data: | |
image: mcr.microsoft.com/mssql/server:2017-latest | |
container_name: dev_sql | |
environment: | |
- SA_PASSWORD=yourStrong(!)Password | |
- ACCEPT_EULA=Y | |
healthcheck: | |
test: ["CMD", "/opt/mssql-tools/bin/sqlcmd", "-Usa", "-PyourStrong(!)Password", "-Q", "select 1"] | |
interval: 1s | |
retries: 20 | |
volumes: | |
- ./sql-scripts:/scripts | |
ports: | |
- "1435:1433" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment