Jump to contentJump to page navigation: previous page [access key p]/next page [access key n]
documentation.suse.com / Documentazione di SUSE Linux Enterprise Server / Virtualization Guide / Managing virtual machines with libvirt / Managing virtual machines with Vagrant
Applies to SUSE Linux Enterprise Server 15 SP3

16 Managing virtual machines with Vagrant

Vagrant is a tool that provides a unified workflow for the creation, deployment and management of virtual development environments. The following sections describe how to manage virtual machines by using Vagrant.

16.1 Introduction to Vagrant

Vagrant provides an abstraction layer for various virtualization providers via a simple configuration file that allows developers and operators to quickly spin up a virtual machine (VM) running Linux or any other operating system.

16.1.1 Vagrant concepts

Vagrant uses providers, provisioners, boxes, and Vagrantfiles as building blocks of the virtual machines.

Vagrant terminology

Services to set up and create virtual environments. Vagrant ships with support for VirtualBox and Microsoft Hyper-V virtualization. Other services such as libvirt, VMware or AWS are supported via plug-ins.


Tools to customize the configuration of virtual environments. Vagrant has built built-in providers for uploading files, synchronizing directories or executing shell commands, but also supports configuration management systems such as Ansible, CFEngine, Chef, Puppet, and Salt.


Configuration file and file name (Vagrantfile) for virtual environments. It contains machine and software requirements and all necessary steps in order to create a development-ready box.


Format and an extension (*.box) for virtual environments. Boxes can be downloaded from the Vagrant Cloud and copied from one machine to another in order to replicate an environment.

SUSE provides official Vagrant Boxes for SUSE Linux Enterprise using the VirtualBox and libvirt providers. SUSE Linux Enterprise Server boxes are available for the AMD64/Intel 64 and AArch64 architectures.

16.1.2 Vagrant example

A new VM can be launched with Vagrant via the following set of commands. This example uses the official Vagrant box for openSUSE Tumbleweed which is available from the Vagrant Cloud.

Procedure 16.1: Creating a Vagrant environment with openSUSE Tumbleweed
  1. Download the Vagrant box for openSUSE Tumbleweed:

    vagrant init opensuse/Tumbleweed.x86_64

    This also registers the box with Vagrant and creates the Vagrantfile.

  2. (Optional) Edit the Vagrantfile to customize the environment.

  3. Start the box:

    vagrant up
  4. Access the box through ssh:

    vagrant ssh

16.2 Vagrant boxes for SUSE Linux Enterprise

Starting with SUSE Linux Enterprise 15 SP2, SUSE provides official Vagrant boxes for SUSE Linux Enterprise using the VirtualBox and libvirt providers. SUSE Linux Enterprise Server boxes are available for the AMD64/Intel 64 and AArch64 architectures, SUSE Linux Enterprise Desktop only for AMD64/Intel 64.

These boxes come with the bare minimum of packages to reduce their size and are not registered, thus users need to register the boxes prior to further provisioning.

The boxes are only available for direct download from https://download.suse.com. Therefore, a downloaded box must be manually registered with Vagrant as follows:

vagrant box add --name SLES-15-SP3 \

The box is then available under the name SLES-15-SP3 and can be used like other Vagrant boxes:

vagrant init SLES-15-SP3
vagrant up
vagrant ssh

16.3 Further reading

For more information about Vagrant and its configuration, refer to the official documentation at https://docs.vagrantup.com/.