<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[OpenTofu - create VM from named template in the configured pool]]></title><description><![CDATA[<p dir="auto">We are successfully using OpenTofu to deploy VMs in a single pool.</p>
<p dir="auto">In our case, we have two pools (Test &amp; Production). XO allows you to create or import a template <em>with the same name</em> into each pool. This is reasonable.</p>
<p dir="auto">When deploying a VM with tofu, first we configure the pool we are using with xenorchestra_pool.  But when we configure xenorchestra_vm and select the template by name, tofu fails because it sees both templates with the same name - and ignores the fact that they are in different pools.</p>
<pre><code>found `2` templates with query {Id: Uuid: Boot:{Firmware: Order:} NameLabel:&lt;my_template_name&gt; PoolId: TemplateInfo:{Arch: Disks:[]} VBDs:[]}. Templates must be uniquely named to use this data source
</code></pre>
<p dir="auto">The templates ARE uniquely named, within their pool, as permitted by XO. Would it be possible please for the tofu VM resource to search for the template in the pool that has been configured?</p>
<p dir="auto">Many thanks,<br />
Graham</p>
]]></description><link>https://xcp-ng.org/forum/topic/12144/opentofu-create-vm-from-named-template-in-the-configured-pool</link><generator>RSS for Node</generator><lastBuildDate>Tue, 05 May 2026 13:07:24 GMT</lastBuildDate><atom:link href="https://xcp-ng.org/forum/topic/12144.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 05 May 2026 09:12:12 GMT</pubDate><ttl>60</ttl></channel></rss>