Initial commit

This commit is contained in:
Daniel Mason 2019-06-02 17:14:11 +12:00
parent bca33f9a16
commit cab26fcb8d
2 changed files with 21 additions and 1 deletions

View file

@ -1,3 +1,4 @@
# pixelfed-upgrade-script
A simple upgrade script to update pixelfed
A simple upgrade script to update pixelfed via cron nightly.

19
update.sh Executable file
View file

@ -0,0 +1,19 @@
#!/bin/bash
# CONFIGURATION #
WEB_ROOT=/var/www/pixelfed
WEB_USER=www-data
# DO NOT EDIT BELOW THIS LINE #
set +x
cd $WEB_ROOT
su - $WEB_USER -s /bin/bash -c 'git pull'
su - $WEB_USER -s /bin/bash -c 'composer install --no-ansi --no-interaction --no-progress --no-scripts --optimize-autoloader'
su - $WEB_USER -s /bin/bash -c 'php artisan config:cache'
su - $WEB_USER -s /bin/bash -c 'php artisan route:cache'
su - $WEB_USER -s /bin/bash -c 'php artisan migrate --force'
su - $WEB_USER -s /bin/bash -c 'php artisan horizon:purge'
su - $WEB_USER -s /bin/bash -c 'php artisan storage:link'