Skip to content

Commit

Permalink
Updated base-image for dockerized tests, examples, GitLab config (yii…
Browse files Browse the repository at this point in the history
  • Loading branch information
schmunk42 authored and samdark committed Nov 17, 2017
1 parent 0f2fa27 commit 821b007
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 19 deletions.
25 changes: 8 additions & 17 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,13 @@
before_script:
# set stack isolation
- export ISOLATION=buildpipeline${CI_PIPELINE_ID}${CI_BUILD_NAME}
- export COMPOSE_PROJECT_NAME=${ISOLATION}
- export TUPLE_C=$(expr ${CI_BUILD_ID} % 99)
- echo ${TUPLE_C}
# run docker-compose commands from tests environment
- cd tests
- cp .env-dist .env
- docker-compose config
image: docker:latest

after_script:
- export ISOLATION=buildpipeline${CI_PIPELINE_ID}${CI_BUILD_NAME}
- export COMPOSE_PROJECT_NAME=${ISOLATION}
# run docker-compose commands from tests environment
services:
- docker:dind

before_script:
- apk add --no-cache python py2-pip git
- pip install --no-cache-dir docker-compose==1.16.0
- docker info
- cd tests
- cp .env-dist .env
- docker-compose down -v --remove-orphans
- docker ps -f name=${ISOLATION}

stages:
- travis
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM dmstr/php-yii2:7.0-fpm-1.9-beta2-alpine-nginx
FROM yiisoftware/yii2-php:7.1-apache

# Project source-code
WORKDIR /project
Expand Down
2 changes: 1 addition & 1 deletion tests/.env-dist
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Choose a flavour
#COMPOSE_FILE=docker-compose.yml:docker-compose.caching.yml
#COMPOSE_FILE=docker-compose.yml:docker-compose.mysql.yml
#COMPOSE_FILE=docker-compose.yml:docker-compose.postgres.yml
#COMPOSE_FILE=docker-compose.yml:docker-compose.pgsql.yml

# Choose a version
DOCKER_MYSQL_IMAGE=percona:5.7
Expand Down
1 change: 1 addition & 0 deletions tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ Run phpunit directly
cd tests
docker-compose run --rm php vendor/bin/phpunit -v --group caching,db
docker-compose run --rm php vendor/bin/phpunit -v --exclude base,caching,db,i18n,log,mutex,rbac,validators,web
docker-compose run --rm php vendor/bin/phpunit -v --exclude mssql,oci,wincache,xcache,zenddata,cubrid

### Cubrid

Expand Down

0 comments on commit 821b007

Please sign in to comment.