21 lines
365 B
Bash
21 lines
365 B
Bash
#!/bin/sh
|
|
|
|
APP_DIR=/var/www/app
|
|
|
|
if [ ! -d "$APP_DIR/.git" ]; then
|
|
git clone https://oauth2:${GIT_TOKEN}@${GIT_REPO} $APP_DIR
|
|
else
|
|
cd $APP_DIR
|
|
git pull
|
|
fi
|
|
|
|
cd $APP_DIR
|
|
|
|
mkdir -p storage bootstrap/cache
|
|
chown -R www-data:www-data storage bootstrap/cache
|
|
chmod -R 775 storage bootstrap/cache
|
|
|
|
composer install --no-interaction --prefer-dist
|
|
|
|
exec php-fpm
|