21 lines
624 B
Bash
Executable File
21 lines
624 B
Bash
Executable File
set -e
|
|
|
|
echo "readonly" | docker login docker.med-logic.ru --username readonly --password-stdin
|
|
|
|
docker pull docker.med-logic.ru/medicine-nginx:latest
|
|
docker pull docker.med-logic.ru/medicine-app:latest
|
|
|
|
unzip /root/medicine-config/backups/medicine.sql.zip -d /root/medicine-config/volumes/files/
|
|
|
|
docker exec -i medicine-stack-postgres psql -U postgres -d medicine -f /files/medicine.sql
|
|
|
|
cd /root/medicine-config/medicine
|
|
if [ ! -f .env ]
|
|
then
|
|
cp env.sample .env
|
|
fi
|
|
|
|
docker-compose run --rm app python manage.py migrate --noinput
|
|
docker-compose run --rm app python manage.py collectstatic --noinput
|
|
docker-compose up -d
|