jsk_travis is a package to test ROS repositories on travis and jenkins.
In order to test on hydro, it uses travis and on indigo and jade, it uses jenkins by default.
On travis, docker can be enabled to test multiple distribution.
Use USE_DOCKER, USE_TRAVIS and USE_JENKINS to configure them manually.
The jenkins server is available on jenkins.jsk.imi.i.u-tokyo.ac.jp.
jsk_travis expects to be added to .travis as submodule.
git submodule add https://github.com/jsk-ros-pkg/jsk_travis.git .travis
And each project needs to setup .travis.yml for the travis. jsk_common's .travis.yml is a good example to setup .travis.yml.
Note that jsk_travis only supports being upgraded and PRs that downgrades jsk_travis result in test fails.
see this document
-
BEFORE_SCRIPT(default: none)BEFORE_SCRIPTis used to specify shell commands which run before building packages. Some characters won't work without escaping it for xml on Jenkins. (see: here) -
BUILD_PKGS(default: none)You can specify the packages to build and test. If your repository has some troubles about several packages, you can ignore them by this option like
BUILD_PKGS="jsk_pcl_ros jsk_recognition_msgs". -
EXTRA_DEB(default: none)You can specify extra deb packages by
EXTRA_DEBvariable. The packages are installed before building packages. -
ROS_DISTRO(required)Specify your target distribution of ROS. Now we support hydro, indigo and jade. If you specify indigo or jade, tests automatically run on jenkins.
-
ROS_PYTHON_VERSION(default: none)Specify your target python version used of ROS. Available from Noetic. see Build Using Python3 and rep 149
-
USE_DEB(value: [true|false|source])If
false, travis firstly sees config files to resolve dependencies, and then installs left dependencies by apt. Ifsource, travis does not sees config files but runssetup_upstream.shfile. See here for example. -
USE_DOCKER(default:false)Force to use docker on travis.
-
DOCKER_IMAGE_JENKINS(defualt:ros-ubuntu:$(lsb_release -sr))Docker image used in Jenkins.
-
DOCKER_RUN_OPTION(default:--rm)Options passed to
docker runifUSE_DOCKERistrue. Ignored otherwise.
NOTE If--rmis not set, the container remains even after job is finished. You must be responsible for removing it. -
USE_JENKINS(default:false)Force to run test on jenkins. jenkins server is more powerful than travis environment, so we can use jenkins to compile pcl-related packages such as jsk_recognition. This variable needs to be
trueto run test with container-based travis environment. This overwrites default configuration described here. -
USE_TRAVIS(default:false)Force test run on travis. This overwrites default configuration described here.
-
CATKIN_PARALLEL_TEST_JOBS(default:-p4)The number of catkin parallel processes in test.
-
CATKIN_TOOLS_BUILD_OPTIONS(default:-iv --summarize --no-statusforcatkin-tools==0.3.Xand--summarize --no-statusforcatkin-toolsof other version.)Options to be passed like
catkin build $CATKIN_TOOLS_BUILD_OPTIONS. -
CATKIN_TOOLS_CONFIG_OPTIONS(default: none)Options to be passed like
catkin config $CATKIN_TOOLS_CONFIG_OPTIONS. -
ROS_PARALLEL_TEST_JOBS(default:-j8)The number of make parallel processes in test.
-
ROSDEP_ADDITIONAL_OPTIONS(default:-n -q -r --ignore-src)The options passed when rosdep install.
-
NOT_TEST_INSTALL(none ortrue, default: none)Flag to skip testing catkin install in addition to devel build.
-
CMAKE_DEVELOPER_ERROR(none ortrue, default: none)Flag to show CMake developer error in catkin run_tests.
-
ADDITIONAL_ENV_TO_DOCKER(default: none)Specify environment variables you want to pass to docker on travis/jenkins. You can specify multiple variables separated by a space.
e.g.IS_EUSLISP_TRAVIS_TEST IS_GAZEBO_TRAVIS_TEST -
DEBUG_TRAVIS_PYTHON(default: none)Specify python command to run within travis/docker/jenkins, for example set
DEBUG_TRAVIS_PYTHONtopython -v
-
.travis.rosinstall,.travis.rosinstall.{{ ROS_DISTRO }}If
USE_DEBisfalse,.travis.rosinstallis used to generate ROS workspace. You can specify distribution by.travis.rosinstall.{{ ROS_DISTRO }}like.travis.rosinstall.indigo.
- relesing jsk_travis package is a bit tricky, due to existance of CATKIN_IGNORE file
mv CATKIN_IGNORE CATKIN_IGNORE.bak
catkin_generate_changelog
emacs -nw CHANGELOG.rst # prettify CHANGELOG so we can understand what has changed
git commit -m "update CHANGELOG" CHANGELOG.rst
catkin_prepare_release --no-push # please type "Y" to all
mv CATKIN_IGNORE.bak CATKIN_IGNORE # do not forget this
gitk # make sure that what you changed is correct
git push && git push --tags
cd docker; make
This will build base images for each distros, such as ros-ubuntu:12.04-base, ros-ubuntu:14.04-base, ros-ubuntu:16.04-base ...
and PCL-installed images ros-ubuntu:14.04-pcl, ros-ubuntu:16.04-pcl ...
Each images are re-build everyday by --build-arg CACHEBUST=$(date +%%Y%%m%%d).
Note that ros-ubuntu:14.04 is used for build process and we do not expect users to run this package. Please use ros-ubuntu:14.04-base instead.
If you add jsk_travis as a submodule, it is difficult to make changes to have the travis test pass. So in that case, I recommend you temporarily set your forked jsk_travis as submodule. The sample commmit is here.
