Containers and virtual machines

Modified: 08 Oct 2018 18:31 UTC

Triton Compute Service provides three classes of compute instances: Docker containers, infrastructure containers, and hardware virtual machines.

Docker containers

Triton is the best place to run Docker. While other Docker run-time environments require complex VM host cluster management and provide only limited networking and security capabilities, Triton transforms an entire data center into an easy to manage, elastic Docker host, while delivering enterprise grade networking and security to each Docker container.

Run Docker images on Triton Virtual Machines or directly on Triton Elastic Docker Host

Infrastructure containers

Leverage container-native Linux on Triton infrastructure containers to extend the benefits of containerization to legacy applications and stateful services, such as databases. Containerizing an application in infrastructure containers is easy because they offer all the services of a typical unix host and behave similarly to hardware virtual machines.

Infrastructure containers enjoy their own virtual NICs, filesystems, and all the resource and security isolation that you'd expect of a Virtual Machine, but with the elastic performance and bursting that's only possible with containers.

Run Linux or SmartOS images directly on bare metal

Triton Virtual Machines

Triton virtual machines (VMs) are hardware virtual machines (HVMs) wrapped in highly secure zones, supporting a variety of images including Linux, FreeBSD, Windows, and Docker Engine. These VMs run on top of a bare-metal hypervisor, meaning it does not need a host operating system to run on resulting in better performance, scalability, and stability than a hosted hypervisor. All VMs get the same high performance networking stack, regardless of the instance type or size.

Each HVM is implemented using a hypervisor: either KVM or bhyve. KVM was the first HVM supported by Triton and remains a strong choice for most VMs, particularly if you are already using KVM in Triton and are satisfied with the performance and features. Bhyve is a newer HVM which aims to immprove performance and scalability, while growing the feature set. Because bhyve is relatively new, not all images are supported on bhyve. In general, HVM images created by Joyent after August, 2018 may be used with either KVM or bhyve. Bhyve is a good choice if the image you need is available for bhyve.

Leverage virtual machines to deploy Windows environments and legacy or special purpose operating systems.

Run Linux, Windows, Docker, and FreeBSD images on Triton virtual machines

Comparing containers vs. virtual machines

It can be difficult to decide which type of infrastructure to use for an application. Below are some example scenarios in which you may decide on using a containerized instance versus a virtual machine.

Purpose Container VM
Secure and high performance
Brand new microservice-based application
Existing application to be converted into microservices
Quickly resize instances without rebooting
Specific environment needs such as FreeBSD, Windows, and Docker Engine
Legacy applications