Build Environment Overview

What This Guide Covers #

This guide provides an overview on the different environments in which Travis CI can run your builds, and why you might want to pick one over another.

Virtualization environments #

Each build runs in one of the following virtual environments.

Linux #

A sudo enabled, full virtual machine per build, that runs Linux, one of:

LXD compliant OS images for arm64 are run in Packet. Have a look at Building on Multiple CPU Architectures for more information.

macOS #

A macOS environment for Objective-C and other macOS specific projects

Windows #

A Windows environment running Windows Server, version 1803.

Virtualisation Environment vs Operating System #

The following table summarizes the differences across virtual environments and operating systems:

  Ubuntu Linux (Bionic, Xenial , Trusty, Precise) macOS Windows Ubuntu Linux / LXD container with (Bionic), Xenial
Name Ubuntu macOS Windows Ubuntu
Status Current Current Early release Early release
Infrastructure Virtual machine on GCE Virtual machine Virtual machine on GCE LXD container on Packet
CPU architecture amd64 amd64 amd64 arm64 (armv8)
.travis.yml dist: bionic or dist: xenial or dist: trusty or dist: precise os: osx os: windows os: linux arch: arm64 dist: bionic or os: linux arch: arm64 dist: xenial
Allows sudo Yes Yes No Yes
Approx boot time 20-50s 60-90s 60-120s <10s
File system EXT4 HFS+ NTFS EXT4
Operating system Ubuntu Linux macOS Windows Server 2016 Ubuntu Linux
Memory 7.5 GB 4 GB 8 GB ~4 GB
Cores 2 2 2 2
IPv4 network IPv4 is available IPv4 is available IPv4 is available IPv4 is available
IPv6 network IPv6 is not available IPv6 is not available IPv6 is not available IPv6 is available
Available disk space approx 18GB approx 41GB approx 19 GB approx 18GB (Arm)

Available disk space is approximate and depends on the base image and language selection of your project. The best way to find out what is available on your specific image is to run df -h as part of your build script.

What infrastructure is my environment running on? #

Usually, knowing the virtualization environment characteristics from the table above is sufficient.

But, if you do need more detail, you have one of these two questions:

For a finished build #

To see what infrastructure a finished build ran on, look at the hostname at the top of the build log:

Infrastructure shown in hostname

if it contains:

  • gce → the build ran in a virtual machine on Google Compute Engine.
  • wjb → the build ran on macOS.
  • 1803-containers → the build ran on Windows.
  • lxd-arm64 → the build ran within an LXD container on Arm64-based infrastructure (currently delivered by Packet)

For a particular .travis.yml configuration #

  • Our default infrastructure is an Ubuntu Linux (os: linux) virtual machine running on AMD64 architecture (arch: amd64), on Google Compute Engine. You can specify which version of Ubuntu using the dist key.

  • Using os: osx, setting a version of Xcode using osx_image:, or using a macOS specific language such as language: objective-c routes your build to macOS infrastructure.

  • Using os: windows routes your build to Windows infrastructure.

  • Using arch: arm64 routes your build to Arm-based LXD containers. You can specify which version of Ubuntu using the dist key.

Deprecated Virtualization Environments #

Historically, Travis CI has provided the following virtualization environments.

If you’re trying to use sudo: false or dist: precise keys in your travis.yml, we recommend you remove them and switch to our current Xenial Linux infrastructure.