-
Notifications
You must be signed in to change notification settings - Fork 8
/
.travis.yml
59 lines (52 loc) · 2.17 KB
/
.travis.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
48
49
50
51
52
53
54
55
56
57
58
sudo: required
language: generic
services:
- docker
branches:
except:
- gh-pages
env:
global:
- CONTAINER_NAME=catkin_pip_docker
# This will check any ROS distro supported on this OS
# checking devel and install separately so that they don't influence each other (dependencies, path, env, etc.)
matrix:
- ROS_DISTRO=indigo ROS_FLOW=devel
- ROS_DISTRO=indigo ROS_FLOW=install
- ROS_DISTRO=jade ROS_FLOW=devel
- ROS_DISTRO=jade ROS_FLOW=install
- ROS_DISTRO=kinetic ROS_FLOW=devel
- ROS_DISTRO=kinetic ROS_FLOW=install
- ROS_DISTRO=lunar ROS_FLOW=devel
- ROS_DISTRO=lunar ROS_FLOW=install
# TODO : test all possible flows (installing deps on devel or not, etc.)
before_install:
# Getting docker ros image
- docker pull ros:${ROS_DISTRO}-ros-core
# Running as daemon
- docker run --name ${CONTAINER_NAME} -d -t ros:${ROS_DISTRO}-ros-core /bin/bash | tee container.id
# Checking current container
- docker ps -a
- docker exec -ti ${CONTAINER_NAME} hostname
- docker exec -ti ${CONTAINER_NAME} uname -a
- docker exec -ti ${CONTAINER_NAME} cat /etc/lsb-release
install:
# refreshing packages
- docker exec -ti ${CONTAINER_NAME} apt-get update
# TMP Patch because rosdep doesnt declare a dependency to sudo yet (2016-08-25) and it doesnt come with xenial
- docker exec -ti ${CONTAINER_NAME} apt-get install sudo -y
- docker exec -ti ${CONTAINER_NAME} rosdep update
# copying local clone to the running container (volume is currently broken)
- docker cp . ${CONTAINER_NAME}:/git_clone
# Installing package dependencies
- docker exec -ti ${CONTAINER_NAME} rosdep install --default-yes --from-paths /git_clone --rosdistro $ROS_DISTRO
# full ROS setup, build and test
script:
- CONTAINER_ID=$(cat container.id)
- docker ps -a
- docker exec -ti ${CONTAINER_NAME} /bin/bash -c "source /opt/ros/$ROS_DISTRO/setup.bash && rospack profile"
# Passing env vars here since passing in docker run currently breaks (2016-08-25)
- docker exec -ti ${CONTAINER_NAME} /bin/bash -c "export ROS_DISTRO=$ROS_DISTRO && export ROS_FLOW=$ROS_FLOW && /git_clone/travis_checks.bash"
- docker stop "${CONTAINER_ID}"
notifications:
email: false