-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy path.gitlab-ci.yml
47 lines (45 loc) · 1.83 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
before_script:
- docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q)
after_script:
- cd docker; docker-compose stop
docker_php7.1_sf:
stage: test
tags:
- docker
only:
- master
script:
- cp docker/.env.dist docker/.env
- bash -c 'sed -i "/\- ..\/sql:\/var\/lib\/mysql/d" docker/docker-compose.yml.dist'
- bash -c 'sed -i "s/.\/logs\/nginx\//\/tmp\/nginx/g" docker/docker-compose.yml.dist'
- cd docker
- bash docker.sh -d
- docker exec -i -u www-data np_php bash -c "cd ../; rm -rf www; composer create-project symfony/website-skeleton www"
- docker-compose stop
- rm nginx/default.conf.dist nginx/silverstripe4.conf.dist
- bash docker.sh -d
- docker exec -i -u www-data np_php bash -c "php bin/phpunit"
- docker exec -i -u www-data np_php bash -c "composer require encore"
- docker exec -i -u www-data np_php bash -c "yarn install"
- docker exec -i -u www-data np_php bash -c "yarn build"
docker_php7.2_sf:
stage: test
tags:
- docker
only:
- master
script:
- cp docker/.env.dist docker/.env
- bash -c 'sed -i "s/7.1/7.2/g" docker/.env'
- bash -c 'sed -i "/\- ..\/sql:\/var\/lib\/mysql/d" docker/docker-compose.yml.dist'
- bash -c 'sed -i "s/.\/logs\/nginx\//\/tmp\/nginx/g" docker/docker-compose.yml.dist'
- cd docker
- bash docker.sh -d
- docker exec -i -u www-data np_php bash -c "cd ../; rm -rf www; composer create-project symfony/website-skeleton www"
- docker-compose stop
- rm nginx/default.conf.dist nginx/silverstripe4.conf.dist
- bash docker.sh -d
- docker exec -i -u www-data np_php bash -c "php bin/phpunit"
- docker exec -i -u www-data np_php bash -c "composer require encore"
- docker exec -i -u www-data np_php bash -c "yarn install"
- docker exec -i -u www-data np_php bash -c "yarn build"