Level 1
Figured it out, maybe this will help someone in the future. Connect Forge to the main repo. And then put the following deploy script. Note rsync -a directory-you-want-to-deploy/ .
cd /home/forge/example.com
git pull origin $FORGE_SITE_BRANCH
rsync -a directory_you_want_to_deploy/ .
( flock -w 10 9 || exit 1
echo 'Restarting FPM...'; sudo -S service $FORGE_PHP_FPM reload ) 9>/tmp/fpmlock
if [ -f artisan ]; then
$FORGE_PHP artisan migrate --force
fi
1 like