Added support for GitLab CI
This commit is contained in:
parent
e8e4112548
commit
c66c7e6dcc
5 changed files with 73 additions and 0 deletions
23
ci/docker_install.sh
Normal file
23
ci/docker_install.sh
Normal file
|
@ -0,0 +1,23 @@
|
|||
#!/bin/bash
|
||||
# From https://docs.gitlab.com/ee/ci/examples/php.html
|
||||
|
||||
# We need to install dependencies only for Docker
|
||||
[[ ! -e /.dockerenv ]] && exit 0
|
||||
|
||||
set -xe
|
||||
|
||||
# Install git (the php image doesn't have it) which is required by composer
|
||||
apt-get update -yqq
|
||||
apt-get install git wget unzip -yqq
|
||||
|
||||
# Install & enable Xdebug for code coverage reports
|
||||
pecl install xdebug
|
||||
docker-php-ext-enable xdebug
|
||||
|
||||
# Install composer dependencies
|
||||
wget https://composer.github.io/installer.sig -O - -q | tr -d '\n' > installer.sig
|
||||
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
|
||||
php -r "if (hash_file('SHA384', 'composer-setup.php') === file_get_contents('installer.sig')) { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
|
||||
php composer-setup.php
|
||||
php -r "unlink('composer-setup.php'); unlink('installer.sig');"
|
||||
php composer.phar install
|
Reference in a new issue