S
S
speedvm2019-07-04 17:03:11
Debian
speedvm, 2019-07-04 17:03:11

How to create your own template for LXC (Proxmox)?

Good day to all!
Virtualization - Proxmox. I want to create my container template using debootstrap.
Tried to do according to this article. The container is created but not launched. Perhaps some detail is missing.
In general terms, the algorithm is as follows:
1. debootstrap --variant=minbase --arch=amd64 stretch debian-mini deb.debian.org/debian
2. <any_config_steps>
3. sudo tar -c[v]pzf mylxc.tar .gz -C debian-mini .
4. Using the template mylxc.tar.gz
Help, dear gurus!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
speedvm, 2019-07-04
@speedvm

https://pve.proxmox.com/wiki/Debian_Appliance_Builder
1. Install dab on Proxmox node:
2. Create build directory:
3. Create dab.conf file with contents:

Suite: stretch
Architecture: amd64
Name: stretch
Version: 9.9-1
Section: system
Maintainer: I
Description: Debian 9.9
 Debian 9.9 Stretch

4. Run:
dab init
dab bootstrap --minimal
dab finalize
mv debian-9.0-stretch_9.9-1_amd64.tar.gz /var/lib/vz/template/cache/
dab clean
dab dist-clean

S
Sanes, 2019-07-04
@Sanes

Better run Virtuozzo/OpenVZ or LXD in a virtual machine. It will make more sense. There templates are made elementary.
The Proxmox developers got into the LXC code, as far as I know.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question