Skip to content
Snippets Groups Projects
Commit c47f6b52 authored by Tim Repke's avatar Tim Repke
Browse files

Merge branch 'server-deployment' into 'production'

bump nacsos-data version

See merge request !12
parents 6846a9e9 669bc245
No related branches found
No related tags found
1 merge request!12bump nacsos-data version
Pipeline #1005 canceled
#!/bin/bash
set -x
echo "Current working directory"
pwd
ls -lisah
whoami
groups
echo "Changing directory and making sure we landed there"
cd /home/nacsos/nacsos-core
pwd
ls -lisah
echo "Stopping NACSOS-core service"
sudo systemctl stop nacsos-core.service
echo "Dropping virtual environment"
rm -rf venv
echo "Fetching updated source"
git config url."https://gitlab-ci-token:$1@gitlab.pik-potsdam.de/".insteadOf "ssh://git@gitlab.pik-potsdam.de/"
git stash # "reset" softly by stashing (in case files changed)
git pull origin production # pull from origin (production branch)
echo "Creating new virtual environment"
python3.10 -m venv venv
source venv/bin/activate
echo "Installing requirements"
pip install -r requirements.txt
echo "Handling migrations"
pip install alembic
cd venv/src/nacsos-data/
alembic upgrade head
echo "Starting NACSOS-core service"
sudo systemctl start nacsos-core.service
\ No newline at end of file
......@@ -9,4 +9,4 @@ httpx[http2]==0.23.1
pymitter==0.4.0
uvicorn==0.20.0
python-multipart==0.0.5
-e git+ssh://git@gitlab.pik-potsdam.de/mcc-apsis/nacsos/nacsos-data.git@34d12771e1f98e2a7f0be8ced77c73d8595f66c2#egg=nacsos_data
-e git+ssh://git@gitlab.pik-potsdam.de/mcc-apsis/nacsos/nacsos-data.git@9bc6466d8a73768801fbf1dd84d27e6a15f072ae#egg=nacsos_data
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment