install.sh 527 Bytes
Newer Older
1 2 3
#!/bin/bash
# Ce script est utilisé pour paramétrer l'environnement du site

4 5 6
cd /home/don/don
git pull origin $CI_BUILD_REF_NAME
git checkout $CI_BUILD_REF_NAME
7 8 9 10 11 12 13

composer install --no-dev
composer update

# Let's run the migrations
if [ -e "phinx.yml" ]
then
14
    case $CI_BUILD_REF_NAME in
15
        master)
16
        	php vendor/robmorgan/phinx/bin/phinx migrate -e production;;
17
        preprod)
18 19
        	php vendor/robmorgan/phinx/bin/phinx migrate -e development;;
    esac
20 21 22 23
else
	php vendor/robmorgan/phinx/bin/phinx init
fi