patterndockerMinor
Multi platform test on Travis-CI using Docker
Viewed 0 times
platformmultidockertravistestusing
Problem
I am trying to write my
The whole concept in a nutshell is (for all 4 distros):
I know how to run scripts inside a docker container but how am I going to get the current branch inside the container and run
Any help will be much appreciated!
.travis.yml to perform multi platform test on Travis-CI using Docker. The platforms I want to test on:- Ubuntu 14.04
- Ubuntu 16.04
- Debian 8
- Debian 9
The whole concept in a nutshell is (for all 4 distros):
docker pull ubuntu:trusty
docker run ubuntu:trusty
- Run
make testinside the container (on my repo's clone)
- Copy the
result.xmlback to Travis
- Run
scp result.xml ${SERVER_USER}@${SERVER_ADDR}:/home/${SERVER_USER}/result/
I know how to run scripts inside a docker container but how am I going to get the current branch inside the container and run
make test on it make me go crazy.Any help will be much appreciated!
Solution
This functionality is built straight into travis. Have a look at here.
Secondly you should not need to specify a branch as part of your make script as travis will triggered on a specific branch and therefore that revision would already be checked out.
Secondly you should not need to specify a branch as part of your make script as travis will triggered on a specific branch and therefore that revision would already be checked out.
Context
StackExchange DevOps Q#4560, answer score: 1
Revisions (0)
No revisions yet.