aswi2020merlot-gitlab/.gitlab-ci.yml @ 06572e80
1 |
image: docker:git |
---|---|
2 |
services: |
3 |
- docker:dind |
4 |
|
5 |
stages: |
6 |
- build |
7 |
- test |
8 |
|
9 |
variables: |
10 |
CONTAINER_TEST_IMAGE: gitlab.kiv.zcu.cz:5000/aswi/aswi-2020/aswi2020merlot |
11 |
|
12 |
before_script: |
13 |
- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab.kiv.zcu.cz:5000 |
14 |
|
15 |
build: |
16 |
stage: build |
17 |
script: |
18 |
- docker build -t $CONTAINER_TEST_IMAGE . |
19 |
- docker push $CONTAINER_TEST_IMAGE |
20 |
|
21 |
unit_test: |
22 |
stage: test |
23 |
script: |
24 |
- cp .env.example .env |
25 |
- composer install |
26 |
- php artisan key:generate |
27 |
- php artisan migrate |
28 |
- vendor/bin/phpunit |