From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <benjamin@gridscale.io>
Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256)
 (No client certificate requested)
 by lists.proxmox.com (Postfix) with ESMTPS id 932C29DD0F
 for <pve-user@lists.proxmox.com>; Tue,  6 Jun 2023 10:59:00 +0200 (CEST)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
 by firstgate.proxmox.com (Proxmox) with ESMTP id 7EB3731CBB
 for <pve-user@lists.proxmox.com>; Tue,  6 Jun 2023 10:59:00 +0200 (CEST)
Received: from mail-qv1-xf2d.google.com (mail-qv1-xf2d.google.com
 [IPv6:2607:f8b0:4864:20::f2d])
 (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)
 key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256)
 (No client certificate requested)
 by firstgate.proxmox.com (Proxmox) with ESMTPS
 for <pve-user@lists.proxmox.com>; Tue,  6 Jun 2023 10:59:00 +0200 (CEST)
Received: by mail-qv1-xf2d.google.com with SMTP id
 6a1803df08f44-6261890b4d7so51669836d6.1
 for <pve-user@lists.proxmox.com>; Tue, 06 Jun 2023 01:58:59 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gridscale-io.20221208.gappssmtp.com; s=20221208; t=1686041930; x=1688633930; 
 h=to:subject:message-id:date:from:mime-version:from:to:cc:subject
 :date:message-id:reply-to;
 bh=va2atgo/llWvfdke0CRP9QCSkIWSaV3qcm56fxnMnCs=;
 b=xpBmInWtR38jSxYipEmd46/VFtJPwOxMcbwS4Es24RteGmdVYYnpKb3luc9Cezf3wD
 eWVy8/C2NMgOhJUN1tHZaonBqwvDBh0nCHDVYqiUfB9OVZ9bN9cUU5CA4VJUPskaUXlk
 AlRCptNjGlGldbwyVQji7g7+bNh3Ta0MKBJCfM1E9yX89S8/yhOJrlKwdfxFG5lO95kX
 D2oUcQv+IJERxIE6El6AGiwDGr1aruF4CYmxwTG6uH5EDnP9cll+NjVZ4Lgf9w4p38HP
 p8VobiVfh1e5P35JWhOKofsfMXJv8sSj51t/7yncjRTDtibmcsJYh6Yg0oQAED/DhOzS
 yktg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20221208; t=1686041930; x=1688633930;
 h=to:subject:message-id:date:from:mime-version:x-gm-message-state
 :from:to:cc:subject:date:message-id:reply-to;
 bh=va2atgo/llWvfdke0CRP9QCSkIWSaV3qcm56fxnMnCs=;
 b=eGtbQTEtuPQtn+PtGO03k6bDdJgAYQwOiJNxnjEV04u1/WLP/kJyBAr+Lj7MLwGV4i
 qVOz9smg7b7ZR8374Td61+M85UpVNkaGLqxHV2C6ANm2mxyXIu0Ul4Ic9tRUgQCAiw2r
 9eF758CCDRicOpQb2c2rPN0dVyn0zkWb3tKRCQDfvNvciIUYcUMOehkc3tbS7x1IgSpq
 9E/2+sAALAvE9XlmkiTFJIGmmLZH3w1AYFoX/tQBjvpN3QuLLyKKkU303On1G0okMocL
 hw+CHAqyU6qNAPLAtBKrYAY2V7Pz07dsrypxr22cUwr08MktG61pX01RWWayu04JfIep
 IXEA==
X-Gm-Message-State: AC+VfDzz9UFh4+8TI4nkmoxjFIFa0L1iqIEnfI055Tk8ySdd2xcM6Ci0
 mOSPPN7t1rNHNxHdSt/t+9mtVKtLG15VIQyQ9P2aUAmAcs91LuJW
X-Google-Smtp-Source: ACHHUZ44PTCNIGtraeBlBGVTNjt9YNWEr5VqxU6un7iWejoJIrOq7n59s7+8JpXc5TLCwfpGCxIHRNsoPhMIqGaJYaM=
X-Received: by 2002:a05:6214:2a89:b0:628:6253:e481 with SMTP id
 jr9-20020a0562142a8900b006286253e481mr1110944qvb.51.1686041930352; Tue, 06
 Jun 2023 01:58:50 -0700 (PDT)
MIME-Version: 1.0
From: Benjamin Hofer <benjamin@gridscale.io>
Date: Tue, 6 Jun 2023 10:58:39 +0200
Message-ID: <CAD=jCXMOhs-b0G-eJw3zeyVcNDV+UrmD8KxTSE6VVO29rM-5ew@mail.gmail.com>
To: pve-user@lists.proxmox.com
X-SPAM-LEVEL: Spam detection results:  0
 AWL 0.138 Adjusted score from AWL reputation of From: address
 BAYES_20               -0.001 Bayes spam probability is 5 to 20%
 DKIM_SIGNED               0.1 Message has a DKIM or DK signature,
 not necessarily valid
 DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature
 DMARC_PASS               -0.1 DMARC pass policy
 HTML_MESSAGE            0.001 HTML included in message
 RCVD_IN_DNSWL_NONE     -0.0001 Sender listed at https://www.dnswl.org/,
 no trust
 SPF_HELO_NONE           0.001 SPF: HELO does not publish an SPF Record
 SPF_PASS               -0.001 SPF: sender matches SPF record
 T_SCC_BODY_TEXT_LINE    -0.01 -
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.29
Subject: [PVE-User] Infrastructure as code with Proxmox: Building templates,
 automated VM/container provisioning
X-BeenThere: pve-user@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Proxmox VE user list <pve-user.lists.proxmox.com>
List-Unsubscribe: <https://lists.proxmox.com/cgi-bin/mailman/options/pve-user>, 
 <mailto:pve-user-request@lists.proxmox.com?subject=unsubscribe>
List-Archive: <http://lists.proxmox.com/pipermail/pve-user/>
List-Post: <mailto:pve-user@lists.proxmox.com>
List-Help: <mailto:pve-user-request@lists.proxmox.com?subject=help>
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-user>, 
 <mailto:pve-user-request@lists.proxmox.com?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2023 08:59:00 -0000

Hi community,

after doing quite some research and testing of tools, I'm still looking for
a proper way of auto-provisioning VMs and containers on Proxmox
(infrastructure as code).
The goal is on the one hand to build base images, on the other hand to have
pipelines setup infrastructure like you would do on public clouds.

Terraform - The inofficial telmate/proxmox provider appeared to be
inreliable in many situations.
Ansible - There are some community modules, but also they weren't reliable,
parameters weren't honored etc.
Cloud-init - works OK, but is implemented in a way that appeared very
unusual to me. I'd expect to be able to pass user-data via the API
directly, like it's the case with many other well-known cloud providers.
Full, API-based automation is difficult with the current implementation.
Packer builder - might do for building VM images, but doesn't seem to
support cloud-init for instance.

Any ideas/thoughts? How to do IaC without writing everything on your own?
I'm quite new to Proxmox, so of course I may be wrong at some of these
points!

Thanks in advance.

All the best
Benjamin