Proxmox Linux Container: Difference between revisions

imported>Vater
Preparing the container: the lxc.init.cmd entry must be ''/sbin/init'' now (nixos 21.11 (tested on pve 7.1))
imported>Altano
Let's be more explicit about what the variables are for shell expansion. This example tripped me up by not working on zsh where the $BUILDID_ variable didn't expand correctly (since '_' was included in the name)
Line 9: Line 9:


<pre>
<pre>
mv nixos-system-x86_64-linux.tar.xz nixos-$RELEASE-default_$BUILDID_amd64.tar.xz
mv nixos-system-x86_64-linux.tar.xz nixos-${RELEASE}-default_${BUILDID}_amd64.tar.xz
</pre>
</pre>


Line 27: Line 27:
pct create 99999 \
pct create 99999 \
   --description nixos-template \
   --description nixos-template \
   local:vztmpl/nixos-$RELEASE-default_$BUILDID_amd64.tar.xz \
   local:vztmpl/nixos-${RELEASE}-default_${BUILDID}_amd64.tar.xz \
   -ostype unmanaged \
   -ostype unmanaged \
   -net0 name=eth0 \
   -net0 name=eth0 \