Feat: dockerize the project with Dockerfile and docker-compose
- Added Dockerfile for containerizing the app. - Created docker-compose.yml for managing services. - Updated connection strings for Docker compatibility.
This commit is contained in:
80
obj/Docker/MergedDockerCompose17.cache
Normal file
80
obj/Docker/MergedDockerCompose17.cache
Normal file
@@ -0,0 +1,80 @@
|
||||
name: dockercompose6909980062609839317
|
||||
services:
|
||||
db:
|
||||
container_name: survey_db
|
||||
environment:
|
||||
POSTGRES_DB: SurveyBeta
|
||||
POSTGRES_PASSWORD: MAJEDali645
|
||||
POSTGRES_USER: postgres
|
||||
healthcheck:
|
||||
test:
|
||||
- CMD-SHELL
|
||||
- pg_isready -U postgres
|
||||
timeout: 5s
|
||||
interval: 10s
|
||||
retries: 5
|
||||
image: postgres:latest
|
||||
networks:
|
||||
default: null
|
||||
ports:
|
||||
- mode: ingress
|
||||
target: 5432
|
||||
published: "5432"
|
||||
protocol: tcp
|
||||
restart: always
|
||||
volumes:
|
||||
- type: volume
|
||||
source: postgres_data
|
||||
target: /var/lib/postgresql/data
|
||||
volume: {}
|
||||
survey-beta:
|
||||
build:
|
||||
context: C:\Users\alioa\Source\Repos\survey-beta2
|
||||
dockerfile: survey-beta/Dockerfile
|
||||
container_name: survey_backend
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_started
|
||||
required: true
|
||||
environment:
|
||||
ASPNETCORE_ENVIRONMENT: Development
|
||||
ASPNETCORE_HTTP_PORTS: "8080"
|
||||
ASPNETCORE_HTTPS_PORTS: "8081"
|
||||
ConnectionStrings__DefaultConnection: Host=postgresql;Database=SurveyBeta;Username=postgres;Password=MAJEDali645
|
||||
image: surveybeta
|
||||
networks:
|
||||
default: null
|
||||
ports:
|
||||
- mode: ingress
|
||||
target: 8080
|
||||
published: "8080"
|
||||
protocol: tcp
|
||||
- mode: ingress
|
||||
target: 8081
|
||||
published: "8081"
|
||||
protocol: tcp
|
||||
- mode: ingress
|
||||
target: 8080
|
||||
protocol: tcp
|
||||
- mode: ingress
|
||||
target: 8081
|
||||
protocol: tcp
|
||||
volumes:
|
||||
- type: bind
|
||||
source: C:\Users\alioa\AppData\Roaming/Microsoft/UserSecrets
|
||||
target: /home/app/.microsoft/usersecrets
|
||||
read_only: true
|
||||
bind:
|
||||
create_host_path: true
|
||||
- type: bind
|
||||
source: C:\Users\alioa\AppData\Roaming/ASP.NET/Https
|
||||
target: /home/app/.aspnet/https
|
||||
read_only: true
|
||||
bind:
|
||||
create_host_path: true
|
||||
networks:
|
||||
default:
|
||||
name: dockercompose6909980062609839317_default
|
||||
volumes:
|
||||
postgres_data:
|
||||
name: dockercompose6909980062609839317_postgres_data
|
||||
Reference in New Issue
Block a user