Slides from the openSUSE Conference 2017 presentation.
The presentation describes the advantages of using Docker at Travis. There 2 described examples how we use it in the YaST team.
3. Travis – Introduction
● CI as a service (hosted)
● Free for open source projects
● Integrated with GitHub
4. Travis
● Builds run in Ubuntu 12.04 (Precise) or 14.04 (Trusty) VM
● 12.04 is discontinued, even 14.04 is pretty old
● What if you need a newer compiler, libraries?
● What if you need a completely different distro?
● Local/remote debugging not possible
6. Docker
● Works out of box at Travis
● Container based, no virtualization
● Lightweight (minimal overhead)
● Many base OS images available
● Easy to build and publish your own images
8. Snapper
● A tool for managing file system snapshots
● Portable, built for many distributions in OBS
● Single Git source repository
● Changed less frequently
9. Snapper – Travis Implementation
● Separate Dockerfile (defines the Docker image)
and build script for each target distribution
● The Docker images are built at Travis
– Easier to maintain
– Takes some more time
● The targets are built in parallel at Travis
12. YaST
● Not portable, (open)SUSE specific
● Does not work in other distributions
● Modular design
● 100+ Git source repositories
● Bigger development team, frequent changes
13. YaST – Old Ubuntu Setup
● Build YaST packages for Ubuntu 12.04 in OBS
– Not a full port! Just enough for running unit tests
(system access is simulated)
● Extra work, hard to maintain
● Not reliable (false positives or uncaught issues)
● Limited scope for tests (cannot build RPM easily)
14. YaST – New Docker Setup
● Pre-built Docker images at Docker Hub
– Faster (only built once)
– Two images for Ruby or C++ packages
– The Travis script is included (shared)
15. Docker at Travis – Summary
● Less maintenace
● More reliable builds
– Using the real target distribution
● Easier debugging
– Use the same Docker image locally
● Independent on Travis default OS
– Ubuntu 12.04 will be dropped soon (switch to 14.04)
21. License
This slide deck is licensed under the Creative Commons Attribution-ShareAlike 4.0 International
license.
It can be shared and adapted for any purpose (even commercially) as long as Attribution is given and
any derivative work is distributed under the same license.
Details can be found at https://creativecommons.org/licenses/by-sa/4.0/
General Disclaimer
This document is not to be construed as a promise by any participating organisation to develop,
deliver, or market a product. It is not a commitment to deliver any material, code, or functionality, and
should not be relied upon in making purchasing decisions. openSUSE makes no representations or
warranties with respect to the contents of this document, and specifically disclaims any express or
implied warranties of merchantability or fitness for any particular purpose. The development, release,
and timing of features or functionality described for openSUSE products remains at the sole discretion
of openSUSE. Further, openSUSE reserves the right to revise this document and to make changes to
its content, at any time, without obligation to notify any person or entity of such revisions or changes.
All openSUSE marks referenced in this presentation are trademarks or registered trademarks of
SUSE LLC, in the United States and other countries. All third-party trademarks are the property of
their respective owners.
Credits
Template
Richard Brown
rbrown@opensuse.org
Design & Inspiration
openSUSE Design Team
http://opensuse.github.io/branding-
guidelines/