Files @ daf93dc32b26
Branch filter:

Location: website/bin/deploy.sh

bsturmfels
Switch content tests to pytest
#!/bin/sh

git push
ssh debian@hickory.sfconservancy.org 'bash -s' << EOF
set -x  # Show output
set -e  # Abort on failure
cd /var/www/website
sudo -u www-data git pull
sudo -u www-data /var/www/venv-website/bin/python3 manage.py check
sudo -u www-data /var/www/venv-website/bin/python3 manage.py migrate
sudo -u www-data /var/www/venv-website/bin/python3 manage.py collectstatic -v0 --noinput --link
sudo systemctl restart apache2
curl --silent --head https://sfconservancy.org | grep --perl-regexp "^HTTP/.+ 200"
EOF