contact@domain.com
1, My Address, My Street, New York City, NY, USA

ENVIRONMENTAL PROTECTION MANAGEMENT

“Step-by-Step Guide to Installing a Container on Proxmox”
Home » Articles  »  “Step-by-Step Guide to Installing a Container on Proxmox”
“Step-by-Step Guide to Installing a Container on Proxmox”

With the open-source platform Proxmox, not only can you manage virtual machines, but you can also conveniently deploy containers. The native format used for this is Linux Containers (LXC) which come with a plethora of templates. The setup and management all occur via a web console, which includes backup functionalities as well.

Upon the relatively straightforward installation of Proxmox, alongside VMs, you also have the capacity to create and operate containers. Ordinarily, these containers are Linux Containers (LXC), as opposed to the more ubiquitous Docker containers. LXC containers function as operating system containers, whereas Docker containers encompass applications.

That said, a Docker environment can also be implemented on Proxmox, an option that can be done within an LXC container or a VM.

This infers that only Linux containers can be operated natively on Proxmox, excluding containers with other operating systems like Windows or FreeBSD. If need be nonetheless, a VM is still a viable alternative.

Containers are administrated using the Proxmox Container Toolkit (PCT), which offers a web-based console in addition to the CLI tool pct.

Downloading container templates

In this section, we will walk through the process of creating a container through the web interface, using the monitoring software Observium for demonstration purposes.

For container installation, click on the Proxmox server's name followed by local<Servername>. The available templates will then be displayed under Container Templates, located on the right.

Using the search field, you will find the desired container templates that you can then download to the local server. For Observium, the turnkey-observium image is available, but there are also alternative images.

After downloading, the image can be found in the Container Templates window. Only these images can be selected in the wizard for creating a container.

Creating a container

Containers can be created by clicking on the Create CT button at the top right of the homepage. This launches a wizard for this task. On the first page, you select the Proxmox server and set the container ID, its name (under "Host"), and a password.

Entering basic data for a new container

In the next dialog, you select the previously downloaded image and the storage on the Proxmox server. At this point, it is also possible to use an Ubuntu image for the container and later install Observium within it via a script.

Selecting a template for the new container

The further configuration is similar to that for other containers. This includes settings for disk space, CPU, memory, network, and DNS. Containers can access the same resources as VMs.

After starting, the container is visible on the web interface and can be used via the Console after clicking on it. Through the container's context menu, you start the environment if it does not boot up automatically.

Settings for a newly created container with observium

Managing and cloning containers

By clicking on a container, you can see the menu items on the right side that allow you to manage containers. Proxmox displays the current resource usage under Overview, which you can edit via the corresponding menu item.

The web console showing the current resource usage of a container

The DNS and Network menu items are responsible for the network settings of the container, while the "Firewall" area handles security.

To create a backup of the container, use Backup. Here, you can create snapshots of the container, which are then found under the corresponding menu item. With these, you can reset containers to an earlier state. User management is done through permissions.

Through the container's context menu on the left side, it is possible to clone the container. Additionally, you can save it with all the set settings as a template. This is then available for creating containers.

Summary

The free virtualization environment Proxmox can run containers in addition to VMs. The native format for this is the LXC specific to Linux, for which numerous templates exist.

After downloading a template from the repository, you can easily create a container based on it with the help of a graphical wizard. This also allows for the convenient adjustment of allocated resources and settings.

Subscribe to 4sysops newsletter!

Individually configured containers can then be saved as templates in turn. The integrated tools also include a backup that secures the state of a container as a snapshot.

Leave a Reply

Your email address will not be published. Required fields are marked *