Mount volume with code from repository in services
We need to mount volume that contains the code that we want to test/we use for tests inside services. We need that for https://gitlab.com/gitlab-org/gitlab-qa/merge_requests/1.
gitlab-ce-test:
variables:
HOSTNAME: gitlab-qa.test
GITLAB_URL: http://$HOSTNAME
image: docker:1.11
services:
- docker:1.11-dind
script:
- docker network create --internal test
- docker run -d --name gitlab-qa --net test --hostname $HOSTNAME gitlab/gitlab-ce:latest
- docker run -t --net test -e GITLAB_URL:$GITLAB_URL -v $(pwd):/tests ruby:2.2 /tests/bin/run
In case like above /tests
directory is empty, because when we execute docker
commands this gets populated to dind
service but there are no files available.
As discussed with @tmaczukin we can fix this problem soon.
/cc @stanhu