1
0
Fork 0

new image

This commit is contained in:
Ilya Mukhortov 2024-03-13 16:39:31 +10:00
parent 70d135211c
commit ecc865c47f
4 changed files with 22 additions and 30 deletions

View File

@ -3,10 +3,6 @@ version: '3'
services: services:
nginx:
external_links:
- "tfoms-patient:patient-search-host"
app: app:
external_links: external_links:
- "tfoms-patient:patient-search-host" - "tfoms-patient:patient-search-host"

View File

@ -3,40 +3,19 @@ version: '3'
services: services:
nginx:
image: docker.med-logic.ru/medicine-nginx:latest
container_name: medicine-nginx
restart: "always"
volumes:
- medicine-public-data:/app/public:ro
links:
- "app:app-host"
ports:
- "${NGINX_PORT}:80"
- "${NGINX_HTTPS_PORT}:443"
networks:
- default
- medicine-network
logging:
driver: "json-file"
options:
max-size: "200k"
max-file: "10"
app: app:
image: docker.med-logic.ru/medicine-app:latest image: docker.med-logic.ru/medicine:latest
container_name: medicine-app container_name: medicine-app
restart: "always" restart: "always"
environment: environment:
UWSGI_PROCESSES: ${UWSGI_PROCESSES} UWSGI_PROCESSES: ${UWSGI_PROCESSES}
UWSGI_THREADS: ${UWSGI_THREADS} UWSGI_THREADS: ${UWSGI_THREADS}
expose: ports:
- "840" - "${NGINX_PORT}:80"
command: /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord.conf - "${NGINX_HTTPS_PORT}:443"
volumes: volumes:
- medicine-public-data:/app/public - medicine-public-data:/app/public
- ./.env:/app/.env - ./.env:/app/.env
- ../volumes/files:/volumes
networks: networks:
- default - default
- medicine-network - medicine-network
@ -50,7 +29,7 @@ services:
max-file: "10" max-file: "10"
tasks: tasks:
image: docker.med-logic.ru/medicine-app:latest image: docker.med-logic.ru/medicine:latest
container_name: medicine-tasks container_name: medicine-tasks
restart: "always" restart: "always"
command: /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord-tasks.conf command: /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord-tasks.conf

4
medicine/restart.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
docker-compose stop
docker-compose up -d

13
medicine/update.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/sh
set -e
echo "readonly" | docker login docker.med-logic.ru --username readonly --password-stdin
docker pull docker.med-logic.ru/medicine:latest
(cd /root/medicine-config/medicine &&
docker-compose stop &&
docker-compose up -d
)
docker rmi $(docker images -f "dangling=true" -q)