git clone ...
php bin/symfony_requirements
export SYMFONY_ENV=prod
composer install --no-dev --optimize-autoloader
php bin/console cache:clear --env=prod --no-debug
chown -R USER:www-data var
php bin/console doctrine:schema:update --force
php bin/console fos:user:create ADMIN_USER ADMIN_EMAIL STRONG_PASSWORD
php bin/console fos:user:promote ADMIN_USER ROLE_ADMIN
php bin/console acme:oauth-server:client:create --grant-type="password" --grant-type="refresh_token" --grant-type="http://platform.local/grants/facebook_access_token" --grant-type="http://platform.local/grants/google_access_token"
git pull
git checkout VERSION
export SYMFONY_ENV=prod
php bin/console doctrine:migrations:migrate
php bin/console cache:clear --env=prod