Last active
September 21, 2019 10:05
-
-
Save SaurabhLpRocks/173b483e923483085e8243d80e10d6c0 to your computer and use it in GitHub Desktop.
This file contains hidden or 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: | |
core-api-service: | |
image: core.api.dev.image | |
container_name: core.api.dev.container | |
build: | |
args: | |
buildconfig: Debug | |
context: . | |
dockerfile: .docker/development.dockerfile | |
environment: | |
- ASPNETCORE_ENVIRONMENT=Development | |
# Set the certificate env variables (We copied certificate from host to below location. See volumes) | |
- Kestrel__Certificates__Default__Path=/root/.dotnet/https/aspnetcore-cert.pfx | |
- Kestrel__Certificates__Default__Password=yourpassword | |
# The .net core base image used in the docker file, runs the app on port 80 by default | |
# Force it to run on ports 5000 & 5001 | |
# Also we are specifying 0.0.0.0 instead of localhost | |
# as the app crashes inside docker when used localhost. | |
- ASPNETCORE_URLS=http://0.0.0.0:5000/;https://0.0.0.0:5001 | |
- DOTNET_USE_POLLING_FILE_WATCHER=true | |
ports: | |
- 5000:5000 | |
- 5001:5001 | |
volumes: | |
# Map the certificate from host to the container | |
- "c:/cert/:/root/.dotnet/https" | |
- "./:/src" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment