From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <pve-devel-bounces@lists.proxmox.com>
Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68])
	by lore.proxmox.com (Postfix) with ESMTPS id C35F51FF162
	for <inbox@lore.proxmox.com>; Sat, 27 Jul 2024 17:10:14 +0200 (CEST)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
	by firstgate.proxmox.com (Proxmox) with ESMTP id 2C35438D9;
	Sat, 27 Jul 2024 17:10:12 +0200 (CEST)
Date: Wed, 17 Jul 2024 18:22:46 +0000
To: pve-devel@lists.proxmox.com
X-Mailman-Approved-At: Sat, 27 Jul 2024 17:10:10 +0200
MIME-Version: 1.0
Message-ID: <mailman.2.1722093010.302.pve-devel@lists.proxmox.com>
List-Id: Proxmox VE development discussion <pve-devel.lists.proxmox.com>
List-Post: <mailto:pve-devel@lists.proxmox.com>
From: LightDiscord via pve-devel <pve-devel@lists.proxmox.com>
Precedence: list
Cc: LightDiscord <root@arnaud.sh>
X-Mailman-Version: 2.1.29
X-BeenThere: pve-devel@lists.proxmox.com
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel>, 
 <mailto:pve-devel-request@lists.proxmox.com?subject=subscribe>
List-Unsubscribe: <https://lists.proxmox.com/cgi-bin/mailman/options/pve-devel>, 
 <mailto:pve-devel-request@lists.proxmox.com?subject=unsubscribe>
List-Archive: <http://lists.proxmox.com/pipermail/pve-devel/>
Reply-To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>
List-Help: <mailto:pve-devel-request@lists.proxmox.com?subject=help>
Subject: [pve-devel] [PATCH proxmox 0/2] Enable upload button for snippets
Content-Type: multipart/mixed; boundary="===============8893601921971661424=="
Errors-To: pve-devel-bounces@lists.proxmox.com
Sender: "pve-devel" <pve-devel-bounces@lists.proxmox.com>

--===============8893601921971661424==
Content-Type: message/rfc822
Content-Disposition: inline

Return-Path: <root@arnaud.sh>
X-Original-To: pve-devel@lists.proxmox.com
Delivered-To: pve-devel@lists.proxmox.com
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))
	(No client certificate requested)
	by lists.proxmox.com (Postfix) with ESMTPS id 8021EC159A
	for <pve-devel@lists.proxmox.com>; Wed, 17 Jul 2024 20:33:05 +0200 (CEST)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
	by firstgate.proxmox.com (Proxmox) with ESMTP id 5F10F701
	for <pve-devel@lists.proxmox.com>; Wed, 17 Jul 2024 20:32:35 +0200 (CEST)
Received: from mail-4327.protonmail.ch (mail-4327.protonmail.ch [185.70.43.27])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits))
	(No client certificate requested)
	by firstgate.proxmox.com (Proxmox) with ESMTPS
	for <pve-devel@lists.proxmox.com>; Wed, 17 Jul 2024 20:32:32 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arnaud.sh;
	s=protonmail; t=1721240572; x=1721499772;
	bh=wUOxfHw5lyeXmY+6F/zdYPBpq9xruNCcK3ipEBrmlpE=;
	h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date:
	 Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector;
	b=u/tCzwCkumyKEFdfypmiJsz+5wRCjouomd9ntZ0fvNz9vkA/x3y5QJW/oTVuNzx6H
	 IAL4SoOwjciez4Spb3xps+L5BkCZoJ1i/bHbdkglTlNb3ZX2MI9uFJSQfRFwU+Cn4Z
	 VLQTNbl8inrGxN7MXwerDNqVlRjEn70BvlZ1OdZfNm6fkUY/ozjH0eUCiijOc/m2jp
	 SJ7wxt1/BRDtXfYXiQSw9ELsQNIwTI4KHkCdnQGTRo++GW20wSbEZ18O8Bad9fFRzJ
	 H2chad9/bwp/GAO4BmwpkjYIAC/aFrd4oN9JTH87sXRC26bNVEEwex6Dbr11Igsm88
	 6Z3LZxn3FrzIw==
Date: Wed, 17 Jul 2024 18:22:46 +0000
To: pve-devel@lists.proxmox.com
From: LightDiscord <root@arnaud.sh>
Subject: [PATCH proxmox 0/2] Enable upload button for snippets
Message-ID: <20240717182228.27812-2-root@arnaud.sh>
Feedback-ID: 8382646:user:proton
X-Pm-Message-ID: 23c1dcc7019d1cee14be13d0fea4940925896312
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-SPAM-LEVEL: Spam detection results:  0
	BAYES_00                 -1.9 Bayes spam probability is 0 to 1%
	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
	DKIM_VALID_AU            -0.1 Message has a valid DKIM or DK signature from author's domain
	DKIM_VALID_EF            -0.1 Message has a valid DKIM or DK signature from envelope-from domain
	DMARC_PASS               -0.1 DMARC pass policy
	SPF_HELO_PASS          -0.001 SPF: HELO matches SPF record
	SPF_PASS               -0.001 SPF: sender matches SPF record
	URIBL_BLOCKED           0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked.  See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [proxmox.com,arnaud.sh]
X-Mailman-Approved-At: Sat, 27 Jul 2024 17:10:10 +0200

Hi everyone,

I wanted to use cloud-init by only interacting with the Web UI on Proxmox.
In all the steps required to do this, we need to reference snippets when=20
using the `cicustom` option. However, it's not possible to upload them
through the UI. It's currently only possible to delete them.

The following two patches attempts to enable the upload route on the API
and enable the upload button on the UI. I've tested both of them and it
seems to work with the tests I did (upload and download from URL small yaml=
=20
files).

NOTE: Some discussions for this feature had concern about the hookscript
snippets, in this case I'm focusing only on cloud-init snippets so I allowe=
d
only `.yml` and `.yaml` files. Some people were also talking about Ignition
maybe enable all extension in the future ?

Reference:

* https://bugzilla.proxmox.com/show_bug.cgi?id=3D2208

NOTE: It's the first time I'm using git send-email and trying to contribute
to multiple repositories at the same time. If the subject of the e-mails or
anything else is wrong, don't hesitate to send me a direct e-mail.




--===============8893601921971661424==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

--===============8893601921971661424==--