Created
April 5, 2020 16:36
-
-
Save ChuckBryan/ec8d27ff1d2171f5d9647e605e164dd6 to your computer and use it in GitHub Desktop.
docker compose with auto volume
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: | |
marathontimetracker.server: | |
image: ${DOCKER_REGISTRY-}marathontimetrackerserver | |
build: | |
context: . | |
dockerfile: MarathonTimeTracker.Server/Dockerfile | |
environment: | |
- DB_PW | |
depends_on: | |
- db | |
db: | |
image: mcr.microsoft.com/mssql/server | |
volumes: | |
- type: volume | |
source: db_data | |
target: /var/opt/mssql | |
environment: | |
SA_PASSWORD: "${DB_PW}" | |
ACCEPT_EULA: "Y" | |
ports: | |
- "1433:1433" | |
volumes: | |
db_data: {} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment