File: //opt/scripts/deploy_demo_feature.sh
#!/bin/bash
echo "Deploy started ..."
cd /var/www/vhost/disk-apps
cd demo.sports-crowd.com/
echo "Execute RESET REPOSITORY ..."
git fetch
git checkout .
git checkout feature/TK-1867-commercial-experiences
git reset --hard
echo "Execute GIT PULL ..."
git pull origin feature/TK-1867-commercial-experiences
sleep 1
#echo "Execute COMPOSER UPDATE ..."
#composer update
#composer install
#sleep 1
echo "Execute MIGRATIONS ..."
php artisan migrate
sleep 1
echo "Execute SEEDERS ..."
composer dump-autoload
php artisan db:seed
sleep 1
echo "Execute clean api swagger ..."
sudo rm -r resources/views/vendor/l5-swagger
php artisan l5-swagger:generate
sleep 1
echo "... Deploy finished"
exit 0