pass
This commit is contained in:
parent
17ffc8249c
commit
b9b286717e
|
|
@ -9,6 +9,7 @@ unzip /root/medicine-config/backups/medicine.sql.zip -d /root/medicine-config/vo
|
|||
docker exec -i medicine-stack-postgres psql -U postgres -d medicine -f /files/medicine.sql
|
||||
|
||||
read -p "Enter organization name: " ORGANIZATION_NAME
|
||||
read -p "Enter organization id: " ORGANIZATION_ID
|
||||
|
||||
SECRET_KEY=$(openssl rand -base64 32)
|
||||
|
||||
|
|
@ -18,6 +19,8 @@ SECRET_KEY=$SECRET_KEY
|
|||
|
||||
SENTRY_SITE=$ORGANIZATION_NAME
|
||||
|
||||
ORGANIZATION_ID=$ORGANIZATION_ID
|
||||
|
||||
EOT
|
||||
|
||||
cd /root/medicine-config/medicine
|
||||
|
|
|
|||
|
|
@ -7,8 +7,7 @@ docker pull docker.med-logic.ru/medicine-remd:latest
|
|||
read -r -p "Create database? [y/N] " response
|
||||
if [[ $prompt =~ [yY](es)* ]]
|
||||
then
|
||||
cd /root/medicine-config/medicine-stack
|
||||
docker-compose exec postgres psql -c 'CREATE DATABASE medicine_remd' --username=postgres
|
||||
docker exec medicine-stack-postgres psql -c 'CREATE DATABASE medicine_remd' --username=postgres
|
||||
fi
|
||||
|
||||
read -p "Enter organization name: " ORGANIZATION_NAME
|
||||
|
|
|
|||
|
|
@ -19,3 +19,4 @@ if test -f "${archive_filename}"; then
|
|||
fi
|
||||
tar -czf "${archive_filename}" "${backup_filename}"
|
||||
rm "${backup_filename}"
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
echo "readonly" | docker login docker.med-logic.ru --username readonly --password-stdin
|
||||
docker pull docker.med-logic.ru/medicine:latest
|
||||
docker run --rm --env-file .env --name medicine-apply-migrations docker.med-logic.ru/medicine:latest python manage.py migrate
|
||||
Loading…
Reference in New Issue