-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
55 lines (55 loc) · 2.36 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# You can override the included template(s) by including variable overrides
# SAST customization: https://docs.gitlab.com/ee/user/application_security/sast/#customizing-the-sast-settings
# Secret Detection customization: https://docs.gitlab.com/ee/user/application_security/secret_detection/#customizing-settings
# Dependency Scanning customization: https://docs.gitlab.com/ee/user/application_security/dependency_scanning/#customizing-the-dependency-scanning-settings
# Note that environment variables can be set in several places
# See https://docs.gitlab.com/ee/ci/variables/#cicd-variable-precedence
cache:
paths:
- vendor/
test:php7.4:
interruptible: true
except:
- /-unstable$/
image: php:7.4
before_script:
- apt-get update -yqq
- apt-get install -yqq git libmcrypt-dev libpq-dev libcurl4-gnutls-dev libicu-dev
libvpx-dev libjpeg-dev libpng-dev libxpm-dev zlib1g-dev libfreetype6-dev libxml2-dev
libexpat1-dev libbz2-dev libgmp3-dev libldap2-dev unixodbc-dev libsqlite3-dev
libaspell-dev libsnmp-dev libpcre3-dev libtidy-dev libyaml-dev libzip-dev
- docker-php-ext-install bz2 curl gd intl json opcache xml zip
- pecl install xdebug
- docker-php-ext-enable xdebug
- echo "xdebug.mode=coverage" >> /usr/local/etc/php/conf.d/xdebug.ini
- cp composer-php74-ci.json composer.json
- rm -f composer.lock
- curl -sS https://getcomposer.org/installer | php
- php composer.phar install
script:
- vendor/bin/phpunit --configuration configuration.xml --coverage-text --colors=never
test:php8.0:
interruptible: true
except:
- /-unstable$/
image: php:8.0
before_script:
- apt-get update -yqq
- apt-get install -yqq git libmcrypt-dev libpq-dev libcurl4-gnutls-dev libicu-dev
libvpx-dev libjpeg-dev libpng-dev libxpm-dev zlib1g-dev libfreetype6-dev libxml2-dev
libexpat1-dev libbz2-dev libgmp3-dev libldap2-dev unixodbc-dev libsqlite3-dev
libaspell-dev libsnmp-dev libpcre3-dev libtidy-dev libyaml-dev libzip-dev
- docker-php-ext-install bz2 gd intl zip
- pecl install xdebug
- docker-php-ext-enable xdebug
- echo "xdebug.mode=coverage" >> /usr/local/etc/php/conf.d/xdebug.ini
- curl -sS https://getcomposer.org/installer | php
- php composer.phar update
script:
- vendor/bin/phpunit --configuration configuration.xml --coverage-text --colors=never
stages:
- test
sast:
stage: test
include:
- template: Security/SAST.gitlab-ci.yml