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 281961FF15E
	for <inbox@lore.proxmox.com>; Tue,  8 Apr 2025 15:33:27 +0200 (CEST)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
	by firstgate.proxmox.com (Proxmox) with ESMTP id BB9EE1E7AD;
	Tue,  8 Apr 2025 15:33:22 +0200 (CEST)
Message-ID: <513cb96a-315e-4c39-b07a-017b4671a0d9@proxmox.com>
Date: Tue, 8 Apr 2025 15:32:49 +0200
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
To: Thomas Lamprecht <t.lamprecht@proxmox.com>,
 Proxmox VE development discussion <pve-devel@lists.proxmox.com>
References: <20250408132517.225240-1-s.hanreich@proxmox.com>
 <3a726979-6d4c-4869-9309-53009ed8f189@proxmox.com>
Content-Language: en-US
From: Stefan Hanreich <s.hanreich@proxmox.com>
In-Reply-To: <3a726979-6d4c-4869-9309-53009ed8f189@proxmox.com>
X-SPAM-LEVEL: Spam detection results:  0
 AWL 0.666 Adjusted score from AWL reputation of From: address
 BAYES_00                 -1.9 Bayes spam probability is 0 to 1%
 DMARC_MISSING             0.1 Missing DMARC policy
 KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment
 SPF_HELO_NONE           0.001 SPF: HELO does not publish an SPF Record
 SPF_PASS               -0.001 SPF: sender matches SPF record
Subject: Re: [pve-devel] [PATCH pve-network 1/1] ipam: netbox: fix adding
 vms without a name set in the options
X-BeenThere: pve-devel@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Proxmox VE development discussion <pve-devel.lists.proxmox.com>
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/>
List-Post: <mailto:pve-devel@lists.proxmox.com>
List-Help: <mailto:pve-devel-request@lists.proxmox.com?subject=help>
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel>, 
 <mailto:pve-devel-request@lists.proxmox.com?subject=subscribe>
Reply-To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: pve-devel-bounces@lists.proxmox.com
Sender: "pve-devel" <pve-devel-bounces@lists.proxmox.com>


On 4/8/25 15:29, Thomas Lamprecht wrote:
> Am 08.04.25 um 15:25 schrieb Stefan Hanreich:
>> The hostname provided to the methods in the IPAM plugins is empty for
>> VMs that do not have a name set. We always included the dns_name key
>> in the request, even if it was undefined, which leads Netbox to return
>> a 400 Bad Request error. With this patch we omit the dns_name
>> parameter if it isn't set, so the call succeeds.
> 
> We default to "CT${VMID}" and "VM${VMID}" in that case though everywhere
> such a hostname is required, that does not make sense here, or?

That doesn't seem to be the case currently, at least during my tests. I
could look into solving it that way, if that's preferred.


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