trying to get this to deploy

This commit is contained in:
2019-11-11 12:30:09 +01:00
parent 708cd8f0e7
commit f3ed56f0e1
12 changed files with 66 additions and 170 deletions

View File

@@ -1,12 +1,16 @@
version: '3.7'
services:
app:
build: .
ports:
- '5001:80'
nginx:
container_name: nginx
image: nginx:latest
depends_on:
- app
ports:
- "80:80"
- '80:80'
networks:
- my-network
volumes:
@@ -20,19 +24,5 @@ services:
- ./data/certbot/conf:/etc/letsencrypt
- ./data/certbot/www:/var/www/certbot
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
app:
build:
context: ./
image: personal_api:0.0.1
container_name: personal_api
env_file:
- ./.env.prod
volumes:
- ./:/personal_api/
command: gunicorn -w 4 -k uvicorn.workers.UvicornWorker personal_api.main:app -b 0.0.0.0
networks:
my-network:
aliases:
- personal-api
networks:
my-network: