build/post_upgrade.sh
changeset 383 82a3db4b1d39
parent 380 b4f69e646e44
child 384 5598bad67f8d
--- a/build/post_upgrade.sh	Fri Oct 21 14:45:47 2016 +0200
+++ b/build/post_upgrade.sh	Fri Oct 21 16:07:19 2016 +0200
@@ -9,19 +9,26 @@
 fi
 
 if [ -d /var/www/corpusdelaparole/corpus-back/ ]; then
-    pushd /var/www/corpusdelaparole/corpus-back/
+    pushd /var/www/corpusdelaparole/corpus-back/ > /dev/null
 
     echo "Migrating back office database"
-    php artisan migrate
+    php artisan migrate -n --force
 
     echo "Optimizing framework"
     php artisan optimize
+    php artisan config:cache
+    php artisan route:cache
+    php artisan view:cache
+
 
     echo "Correcting file permissions for back office"
     chgrp -R apache storage bootstrap/cache
     chmod -R ug+rwx storage bootstrap/cache
 
-    popd
+    echo "Put back application in production"
+    php artisan up
+
+    popd > /dev/null
 fi
 
 echo "Restart httpd"