<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Cloud on Bastien Traverse</title>
    <link>https://bastientraverse.com/en/tags/cloud/</link>
    <description>Recent content in Cloud on Bastien Traverse</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Fri, 04 Oct 2024 00:00:00 +0200</lastBuildDate><atom:link href="https://bastientraverse.com/en/tags/cloud/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Optimized cloud-init templates on Proxmox</title>
      <link>https://bastientraverse.com/en/proxmox-optimized-cloud-init-templates/</link>
      <pubDate>Fri, 04 Oct 2024 00:00:00 +0200</pubDate>
      
      <guid>https://bastientraverse.com/en/proxmox-optimized-cloud-init-templates/</guid>
      <description>&lt;p&gt;There are already quite a few resources out there demonstrating how to create a cloud-init enabled VM template in Proxmox. Here are the ones I mainly used to discover the topic, and which I suggest you go through because what follows depends on them:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Proxmox &lt;a href=&#34;https://pve.proxmox.com/wiki/Cloud-Init_FAQ&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;FAQ&lt;/a&gt;, &lt;a href=&#34;https://pve.proxmox.com/wiki/Cloud-Init_Support&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;wiki&lt;/a&gt; and mostly identical &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_cloud_init&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;official documentation&lt;/a&gt; on Cloud-Init support&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://youtu.be/shiIi38cJe4&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Perfect Proxmox Template with Cloud Image and Cloud Init&lt;/a&gt; (YouTube, Techno Tim 2022-03)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;What those and many similar resources give are step-by-step instructions divided in as many commands to facilitate understanding. What I haven&amp;rsquo;t seen so far though, is an &lt;em&gt;all-in-one, optimized&lt;/em&gt; command to do the same thing, so here&amp;rsquo;s my contribution to the field:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm create &lt;span class=&#34;m&#34;&gt;1000&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --name debian12-cloud &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --description &lt;span class=&#34;s2&#34;&gt;&amp;#34;Debian 12 cloud-init template&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --template &lt;span class=&#34;m&#34;&gt;1&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --ostype l26 &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --machine q35 &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --cpu host &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --cores &lt;span class=&#34;m&#34;&gt;2&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --memory &lt;span class=&#34;m&#34;&gt;4096&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --balloon &lt;span class=&#34;m&#34;&gt;512&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --scsihw virtio-scsi-single &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --scsi0 local-lvm:0,import-from&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;/path/to/debian-12-generic-amd64.qcow2,discard&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;on,iothread&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;1,ssd&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;m&#34;&gt;1&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --net0 virtio,bridge&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;vmbr0 &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --tablet &lt;span class=&#34;m&#34;&gt;0&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --rng0 &lt;span class=&#34;nv&#34;&gt;source&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;/dev/urandom &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --boot &lt;span class=&#34;nv&#34;&gt;order&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;scsi0 &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --vga serial0 --serial0 socket &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --ide2 local-lvm:cloudinit &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --ciuser myuser &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --cipassword changeme &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --sshkey /path/to/your-public.key &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --ciupgrade &lt;span class=&#34;m&#34;&gt;0&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    --ipconfig0 &lt;span class=&#34;nv&#34;&gt;ip&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;dhcp
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The same thing as a one-liner for the latest Ubuntu:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm create &lt;span class=&#34;m&#34;&gt;2000&lt;/span&gt; --name ubuntu-server-2404-cloud --description &lt;span class=&#34;s2&#34;&gt;&amp;#34;Ubuntu Server 24.04 cloud-init template&amp;#34;&lt;/span&gt;  --template &lt;span class=&#34;m&#34;&gt;1&lt;/span&gt; --ostype l26 --machine q35 --cpu host --cores &lt;span class=&#34;m&#34;&gt;2&lt;/span&gt; --memory &lt;span class=&#34;m&#34;&gt;4096&lt;/span&gt; --balloon &lt;span class=&#34;m&#34;&gt;512&lt;/span&gt; --scsihw virtio-scsi-single --scsi0 local-lvm:0,import-from&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;/path/to/ubuntu-24.04-server-cloudimg-amd64.img,discard&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;on,iothread&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;1,ssd&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;m&#34;&gt;1&lt;/span&gt; --net0 virtio,bridge&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;vmbr0 --rng0 &lt;span class=&#34;nv&#34;&gt;source&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;/dev/urandom --tablet &lt;span class=&#34;m&#34;&gt;0&lt;/span&gt; --boot &lt;span class=&#34;nv&#34;&gt;order&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;scsi0 --vga serial0 --serial0 socket --ide2 local-lvm:cloudinit --ciuser myuser --cipassword changeme --sshkey /path/to/your-public.key --ciupgrade &lt;span class=&#34;m&#34;&gt;0&lt;/span&gt; --ipconfig0 &lt;span class=&#34;nv&#34;&gt;ip&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;dhcp
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Note that you cannot copy-paste those blindly, you have to adjust a few parameters to your local environment (especially the VMID, disk image and SSH key paths).&lt;/p&gt;
&lt;p&gt;Follows a description of relevant options at the exclusion of self-evident ones (&lt;code&gt;name&lt;/code&gt;, &lt;code&gt;description&lt;/code&gt;, &lt;code&gt;cores&lt;/code&gt;, &lt;code&gt;memory&lt;/code&gt;&amp;hellip;), as well as some possible variations you might want.&lt;/p&gt;
&lt;h3 id=&#34;generic-options&#34;&gt;&lt;a href=&#34;#generic-options&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Generic options&lt;/h3&gt;&lt;ul&gt;
&lt;li&gt;&lt;code&gt;qm create 1000&lt;/code&gt;: the Proxmox CLI command to create a VM. Replace &lt;code&gt;1000&lt;/code&gt; by the VMID of your choice (must be ≥ 100)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--template 1&lt;/code&gt;: directly convert the created VM to a template&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;performance-related-options&#34;&gt;&lt;a href=&#34;#performance-related-options&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Performance related options&lt;/h3&gt;&lt;ul&gt;
&lt;li&gt;&lt;code&gt;--ostype l26&lt;/code&gt;: hint to optimize for a Linux 2.x-6.x-based system&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--machine q35&lt;/code&gt;: use a modern &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_machine_type&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;machine type&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--cpu host&lt;/code&gt;: pass-through the host &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#_cpu_type&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;CPU type&lt;/a&gt; to make all its features available in the VM&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--balloon 512&lt;/code&gt;: when set to a lower value than &lt;code&gt;memory&lt;/code&gt;, enables &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_memory&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;dynamic memory allocation&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--scsihw virtio-scsi-single&lt;/code&gt;: the most performant &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_hard_disk&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;SCSI controller&lt;/a&gt;, especially when combined with &lt;code&gt;iothread=1&lt;/code&gt; (see next point)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--scsi0 local-lvm:0,import-from=/path/to/debian-12-generic-amd64.qcow2,iothread=1,discard=on,ssd=1&lt;/code&gt;:
&lt;ul&gt;
&lt;li&gt;import (&lt;em&gt;i.e.&lt;/em&gt; copy) the referenced cloud image as the VM disk
&lt;ul&gt;
&lt;li&gt;replace &lt;code&gt;/path/to/&lt;/code&gt; with the full path to where you downloaded the cloud image (which you should have already done by now if you have followed the resources linked above 😉)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;configure it with performance (&lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_hard_disk_iothread&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;IO Thread&lt;/a&gt;), &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_hard_disk_discard&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;thin-provisioning&lt;/a&gt; and SSD-optimized settings
&lt;ul&gt;
&lt;li&gt;remove &lt;code&gt;discard=on&lt;/code&gt; and/or &lt;code&gt;ssd=1&lt;/code&gt; if not applicable to your storage&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--tablet 0&lt;/code&gt;: one of the lesser-known performance tips but one of the most important! &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_options&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Disables the USB tablet device&lt;/a&gt; only needed when connecting via the integrated console to guests with a GUI (&lt;em&gt;e.g.&lt;/em&gt; Ubuntu Desktop). Reported to have a &lt;a href=&#34;https://reddit.com/r/homelab/comments/q1m383/a_small_but_useful_tip_for_proxmox_users/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;big performance impact&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--rng0 source=/dev/urandom&lt;/code&gt; (optional): provides a &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_virtio_rng&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;virtual hardware random number generator&lt;/a&gt; to get entropy from the host system (can speed things up during the first boot)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Up to here were performance-related options applicable to all VM templates, not only cloud-init ones. Here comes the cloud-init specific bits:&lt;/p&gt;
&lt;h3 id=&#34;cloud-init-related-options&#34;&gt;&lt;a href=&#34;#cloud-init-related-options&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Cloud-init related options&lt;/h3&gt;&lt;ul&gt;
&lt;li&gt;&lt;code&gt;--boot order=scsi0&lt;/code&gt;: apparently &lt;a href=&#34;https://pve.proxmox.com/wiki/Cloud-Init_Support#_preparing_cloud_init_templates&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;speeds up booting&lt;/a&gt; for cloud-init enabled images&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--vga serial0 --serial0 socket&lt;/code&gt;: creates the serial connection &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_cloud_init&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;expected by most cloud images&lt;/a&gt; in their &amp;ldquo;native&amp;rdquo; cloud environments; also useful to monitor and troubleshoot the boot process via the Proxmox console
&lt;ul&gt;
&lt;li&gt;verified to work with Debian 12 and Ubuntu 24.04 server  cloud images; remove if causing issues with the image you&amp;rsquo;re using&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--ide2 local-lvm:cloudinit&lt;/code&gt;: creates the required cloud-init &amp;ldquo;CD-ROM&amp;rdquo; drive&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--ciuser myuser&lt;/code&gt; (optional): provides a custom username for the user account provisioned by cloud-init; without it the account name will depend on the distribution&amp;rsquo;s default (&lt;code&gt;debian&lt;/code&gt; for Debian, &lt;code&gt;ubuntu&lt;/code&gt; for Ubuntu&amp;hellip; Check your cloud image docs about this)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--cipassword changeme&lt;/code&gt; (optional): generally not needed nor recommended, but useful for quickly making sure everything is all right the first few times over; afterwards use a SSH key instead&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--sshkey /path/to/your-public.key&lt;/code&gt; (&lt;strong&gt;required&lt;/strong&gt; if not setting a password): the authorized SSH public key that will be placed in the user account created by cloud-init&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--ciupgrade 0&lt;/code&gt; (optional): disable automatically upgrading packages during first boot; useful to speed things up during testing, afterwards remove it/set it to &lt;code&gt;1&lt;/code&gt; (the default) if you want &amp;ldquo;always fresh&amp;rdquo; clones (which is probably a smart choice)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--ipconfig0 ip=dhcp&lt;/code&gt;: cloud-init in Proxmox doesn&amp;rsquo;t have a network configuration by default, so use this to let DHCP handle it or use something like &lt;code&gt;--ipconfig0 ip=10.0.10.123/24,gw=10.0.10.1&lt;/code&gt; for static config. Can be done later for each VM individually, just don&amp;rsquo;t leave it empty otherwise they won&amp;rsquo;t have any network by default.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you already have &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#_custom_cloud_init_configuration&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;custom cloud-init snippets&lt;/a&gt;, specify them via &lt;code&gt;--cicustom &amp;quot;user=&amp;lt;volume&amp;gt;,network=&amp;lt;volume&amp;gt;,meta=&amp;lt;volume&amp;gt;&amp;quot;&lt;/code&gt;, &lt;em&gt;e.g.&lt;/em&gt; &lt;code&gt;--cicustom &amp;quot;user=local:snippets/user-config.yaml&amp;quot;&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;If you do, &lt;strong&gt;make sure you have the equivalents of the Proxmox cloud-init options above set in your custom config&lt;/strong&gt;, because &lt;a href=&#34;https://forum.proxmox.com/threads/proxmox-ignores-custom-cloud-init-from-cicustom-paramter-tested-with-ubuntu-centos.78070/#post-346322&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;using a custom user snippet overrides the complete user config set in the GUI or config&lt;/a&gt;! Yeah I know, it sucks and it&amp;rsquo;s not documented, boo Proxmox.&lt;/p&gt;
&lt;p&gt;Fortunately, as mentioned in the docs the GUI config can be dumped to serve as a base for custom configs:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm cloudinit dump &lt;span class=&#34;m&#34;&gt;1000&lt;/span&gt; user
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm cloudinit dump &lt;span class=&#34;m&#34;&gt;1000&lt;/span&gt; network
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class=&#34;admonition info&#34;&gt;&lt;p class=&#34;admonition-title&#34;&gt;Note&lt;/p&gt;
  Unlike Proxmox&amp;rsquo; implementation, when using &lt;code&gt;--cicustom&lt;/code&gt; and in the absence of network configuration, the image&amp;rsquo;s &lt;code&gt;cloud-init&lt;/code&gt; process will generate a network configuration that will issue a DHCP request on a “first” network interface. So if DHCP is what you want, you don&amp;rsquo;t have to supply a &lt;code&gt;&amp;quot;network:...&amp;quot;&lt;/code&gt; snippet besides the &lt;code&gt;&amp;quot;user:...&amp;quot;&lt;/code&gt; one.
&lt;/div&gt;
&lt;h2 id=&#34;post-creation-steps&#34;&gt;&lt;a href=&#34;#post-creation-steps&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Post-creation steps&lt;/h2&gt;&lt;p&gt;The only thing that cannot be done in the same step (due to using &lt;code&gt;import-from&lt;/code&gt;) is resizing the disk image. I personally prefer doing it on the cloned VMs rather than on the template itself to reduce cloning time and adjust the size depending on the VM&amp;rsquo;s needs, but there is also a case to be made to do it on the template directly.&lt;/p&gt;
&lt;p&gt;So in my case I first clone the template to a new VM:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm clone &lt;span class=&#34;m&#34;&gt;1000&lt;/span&gt; &lt;span class=&#34;m&#34;&gt;150&lt;/span&gt; --full --name &lt;span class=&#34;s2&#34;&gt;&amp;#34;debian12-cloud&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class=&#34;admonition note&#34;&gt;&lt;p class=&#34;admonition-title&#34;&gt;Note&lt;/p&gt;
  &lt;p&gt;Besides being generally recommended for VMs you will keep around, it seems we can only use a &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_copy_and_clone&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;full clone&lt;/a&gt; when using &lt;code&gt;--scsihw virtio-scsi-single&lt;/code&gt; as without the  &lt;code&gt;--full&lt;/code&gt; option I get:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Linked clone feature is not supported for drive &#39;scsi0&#39;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;YMMV.&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;Then expand its disk size:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm resize &lt;span class=&#34;m&#34;&gt;150&lt;/span&gt; scsi0 15G
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And then we&amp;rsquo;re ready to fire up the VM!&lt;/p&gt;
&lt;div class=&#34;admonition tip&#34;&gt;
  Double-click on the VM name (or on the &amp;ldquo;Console&amp;rdquo; button at the top right) instead of going through the integrated VM-specific menu &amp;ldquo;Console&amp;rdquo; element, because the pop-up window it opens can be resized fullscreen and allows to scroll back the buffer and read the boot log if necessary.
&lt;/div&gt;
&lt;p&gt;After checking everything works, you may want to stop and destroy this test VM:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm stop &lt;span class=&#34;m&#34;&gt;150&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;qm destroy &lt;span class=&#34;m&#34;&gt;150&lt;/span&gt; --purge --destroy-unreferenced-disks &lt;span class=&#34;m&#34;&gt;1&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now you can do the final adjustments to your template (&lt;em&gt;e.g.&lt;/em&gt; remove &lt;code&gt;--cipassword&lt;/code&gt;, &lt;code&gt;--ciupgrade 0&lt;/code&gt; etc.) and you are ready to rock the cloud-init lifestyle in Proxmox! ☁️🤘🕺&lt;/p&gt;
&lt;h2 id=&#34;uefi-variant&#34;&gt;&lt;a href=&#34;#uefi-variant&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;UEFI variant&lt;/h2&gt;&lt;p&gt;Generally I try to use as modern a stack as is reasonable, because software written in the last few years is more likely to be tested with it than a more legacy stack.&lt;/p&gt;
&lt;p&gt;But I have realized that &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_bios_and_uefi&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;UEFI&lt;/a&gt; is much less commonplace in virtualized environments than on bare metal, making it less tested and I&amp;rsquo;d say, slightly less supported overall (case in point: it&amp;rsquo;s still not the default in QEMU/Proxmox).&lt;/p&gt;
&lt;p&gt;However it is easy enough to use it in our templates by adding the following options:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;--bios ovmf --efidisk0 local-lvm:0,efitype&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;4m,size&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;4M,pre-enrolled-keys&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;m&#34;&gt;0&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The only thing to note is that &lt;code&gt;pre-enrolled-keys=0&lt;/code&gt; disables Secure Boot, which trips up all the distros that don&amp;rsquo;t want to play the Microsoft game (Arch Linux being a notable one for me). Leave the parameter out or switch its value to &lt;code&gt;1&lt;/code&gt; for a Secure Boot-enabled template (confirmed working with Ubuntu for example)!&lt;/p&gt;
&lt;h2 id=&#34;the-qemu-guest-agent-conundrum&#34;&gt;&lt;a href=&#34;#the-qemu-guest-agent-conundrum&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;The QEMU Guest Agent conundrum&lt;/h2&gt;&lt;p&gt;By default, no cloud images I know of come with &lt;code&gt;qemu-guest-agent&lt;/code&gt; preinstalled, but it&amp;rsquo;s &lt;a href=&#34;https://pve.proxmox.com/wiki/Qemu-guest-agent&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;pretty&lt;/a&gt; &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_qemu_agent&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;useful&lt;/a&gt; on Proxmox.&lt;/p&gt;
&lt;p&gt;To install it in your cloud images, you basically have two options:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Install and use libguestfs&amp;rsquo; &lt;a href=&#34;https://libguestfs.org/virt-customize.1.html&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;virt-customize&lt;/a&gt; to the cloud images themselves, as illustrated &lt;a href=&#34;https://totaldebug.uk/posts/proxmox-template-with-cloud-image-and-cloud-init/#install-packages&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;in this random blog post I found&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Let cloud-init do it during the first boot of each cloned VM using a &lt;a href=&#34;https://pve.proxmox.com/pve-docs/chapter-qm.html#_custom_cloud_init_configuration&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;custom cloud-init snippet&lt;/a&gt;: see &lt;a href=&#34;https://superuser.com/a/1787022&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;this SuperUser answer&lt;/a&gt; for an example. The required lines to add to your &lt;code&gt;user-config.yaml&lt;/code&gt; are:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-yaml&#34; data-lang=&#34;yaml&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;#cloud-config&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;...&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;package_update&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;packages&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;  &lt;/span&gt;- &lt;span class=&#34;l&#34;&gt;qemu-guest-agent&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;runcmd&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;  &lt;/span&gt;- &lt;span class=&#34;l&#34;&gt;systemctl enable --now qemu-guest-agent&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;Remember that using a custom user snippet &lt;a href=&#34;https://forum.proxmox.com/threads/proxmox-ignores-custom-cloud-init-from-cicustom-paramter-tested-with-ubuntu-centos.78070/#post-346322&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;overrides the complete user config set in the GUI or config&lt;/a&gt;, so those lines must be added to your complete user snippet!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In this case add &lt;code&gt;--cicustom &amp;quot;user=local:snippets/user-config.yaml&amp;quot;&lt;/code&gt; and&lt;code&gt;--agent 1,fstrim_cloned_disks=1&lt;/code&gt; when creating the template (see &lt;a href=&#34;https://pve.proxmox.com/pve-docs/qm.1.html&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;the docs&lt;/a&gt; for details).&lt;/p&gt;
&lt;h2 id=&#34;tips--tricks&#34;&gt;&lt;a href=&#34;#tips--tricks&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Tips &amp;amp; tricks&lt;/h2&gt;&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;don&amp;rsquo;t use Debian &lt;code&gt;genericcloud&lt;/code&gt; image: its kernel is optimized for Azure &amp;amp; AWS environments and in my tests, didn&amp;rsquo;t work with Proxmox. I had started with this one (being fooled by the wording on &lt;a href=&#34;https://cdimage.debian.org/images/cloud/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;the download page&lt;/a&gt; (&amp;quot;&lt;em&gt;genericcloud: Similar to generic. Should run in any virtualised environment. Is smaller than &lt;code&gt;generic&lt;/code&gt; by excluding drivers for physical hardware&lt;/em&gt;&amp;quot;), spent quite a bit of time troubleshooting the VM booting but cloud-init not kicking in, until I eventually tried the &lt;code&gt;generic&lt;/code&gt; image where everything worked perfectly. &lt;a href=&#34;https://wiki.debian.org/Cloud/#What_is_the_difference_between_the_generic_and_genericcloud_images.3F&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;The Debian wiki&lt;/a&gt; actually sets the record straight:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The generic image uses Debian&amp;rsquo;s standard Linux kernel packages, while the genericcloud image uses the cloud kernel build. The cloud kernel disables a large number of device drivers and primarily targets the Amazon EC2 and Microsoft Azure VM device models. It may be usable in other environments, but for maximum compatibility we recommend using the generic images.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;While troubleshooting I&amp;rsquo;ve seen plenty of other reports of people having issues making the &lt;code&gt;genericcloud&lt;/code&gt; image work with Proxmox, while it worked for some others&amp;hellip; &lt;code&gt;generic&lt;/code&gt; is the reliable, consistant option. &amp;rsquo;nough said!&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;you can get Proxmox to display &lt;code&gt;.qcow2&lt;/code&gt; images alongside regular &lt;code&gt;.iso&lt;/code&gt; in its GUI, by simply suffixing/replacing their extension with &lt;code&gt;.img&lt;/code&gt; (like Ubuntu does). It&amp;rsquo;s a regex issue ¯\_(ツ)_/¯&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
</description>
    </item>
    
    <item>
      <title>Using a container to sidestep a forgotten password in CasaOS</title>
      <link>https://bastientraverse.com/en/casa-password-recovery/</link>
      <pubDate>Sat, 03 Feb 2024 00:00:00 +0100</pubDate>
      
      <guid>https://bastientraverse.com/en/casa-password-recovery/</guid>
      <description>&lt;h2 id=&#34;problem-statement&#34;&gt;&lt;a href=&#34;#problem-statement&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Problem statement&lt;/h2&gt;&lt;p&gt;As part of dabbling with self-hosting again, I installed &lt;a href=&#34;https://github.com/IceWhaleTech/CasaOS&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;CasaOS&lt;/a&gt; on an Oracle Cloud free Ampere instance to try it out.&lt;/p&gt;
&lt;p&gt;After setting it aside for a few weeks, when I logged in via SSH and tried to use &lt;code&gt;sudo&lt;/code&gt; I realized I absolutely couldn&amp;rsquo;t remember my user&amp;rsquo;s password 😅&lt;/p&gt;
&lt;p&gt;The standard operating procedure in this case is to either reboot the machine on a live system and use that to chroot into the local install, or fiddle with GRUB rescue/kernel command line.&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt;&lt;/p&gt;
&lt;p&gt;But since I could still install containers through CasaOS web interface, I thought I&amp;rsquo;d use this opportunity to explore ways to recover my sudo access/change my password without rebooting (which could be nice in case it is essential to avoid downtime).&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Edit:&lt;/strong&gt; As I was finishing this post, I realized that the third constraint listed below was incorrect, and as a result a less cumbersome resolution was possible. So read on if you are interested in the learning journey, or jump straight to &lt;a href=&#34;#the-solution-simplified&#34;&gt;the simplified solution&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id=&#34;the-constraints&#34;&gt;&lt;a href=&#34;#the-constraints&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;The constraints&lt;/h2&gt;&lt;ul&gt;
&lt;li&gt;the CLI/SSH access is &amp;ldquo;useless&amp;rdquo;: my user is not setup to interact with the Docker socket without elevated privileges (which is usually a good thing)&lt;/li&gt;
&lt;li&gt;besides its App Store content, CasaOS allows to manually install containers using a Compose file or a &lt;code&gt;docker run&lt;/code&gt; command (which is then &lt;a href=&#34;https://www.composerize.com/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;composerized&lt;/a&gt;): see &lt;a href=&#34;https://youtu.be/ToV6vRIl3Nk?si=HH9YiQdyqy2LDsva&amp;amp;t=16&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;official video&lt;/a&gt; or &lt;a href=&#34;https://docs.zimaboard.com/docs/Self-Deploying-Applications.html#Follow-these-steps-in-order&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;screenshots&lt;/a&gt; of the process&lt;/li&gt;
&lt;li&gt;&lt;del&gt;its interface however doesn&amp;rsquo;t allow to &lt;code&gt;docker exec&lt;/code&gt; or interact with containers in any other way; the installed containers &lt;em&gt;must&lt;/em&gt; expose a web interface for us to be able to interact with them.&lt;/del&gt; As it turns out, CasaOS interface does &lt;a href=&#34;https://github.com/IceWhaleTech/CasaOS/issues/1316&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;offer access to containers&amp;rsquo; console&lt;/a&gt; (equivalent to a &lt;code&gt;docker exec -it &amp;lt;containe&amp;gt; /bin/sh&lt;/code&gt;), at least for apps installed from its official Store, via the app Settings &amp;gt; &amp;ldquo;Terminal and Logs&amp;rdquo; icon.&lt;/li&gt;
&lt;/ul&gt;
&lt;figure class=&#34;center&#34;&gt;&lt;img src=&#34;https://bastientraverse.com/en/casa-password-recovery/casa-app-settings-terminal.png&#34;
    alt=&#34;Access to a container shell and logs in CasaOS interface&#34;&gt;&lt;figcaption&gt;
      &lt;h4&gt;Access to a container shell and logs in CasaOS interface&lt;/h4&gt;
    &lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2 id=&#34;hacking-around&#34;&gt;&lt;a href=&#34;#hacking-around&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Hacking around&lt;/h2&gt;&lt;p&gt;Because I&amp;rsquo;m pretty new to this, my first idea was to start a container which would give me a root shell with access to the docker socket, and then use that environment to start a second privileged container (&lt;a href=&#34;https://www.docker.com/blog/docker-can-now-run-within-docker/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Docker-in-Docker&lt;/a&gt; style) from which I would mount the host filesystem and use &lt;code&gt;{ch,}passwd&lt;/code&gt; or such&amp;hellip; Yes, I felt very smart thinking this up 😅&lt;/p&gt;
&lt;p&gt;Unaware of my mistaken approach, I looked online for a &amp;ldquo;web terminal container&amp;rdquo; and the first result on StartPage was the &lt;a href=&#34;https://github.com/raonigabriel/web-terminal&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;web terminal&lt;/a&gt; GitHub repo, which did what I needed (expose a root shell in the browser) but hadn&amp;rsquo;t been updated since August 2021 😕&lt;/p&gt;
&lt;figure class=&#34;center&#34;&gt;&lt;img src=&#34;https://bastientraverse.com/en/casa-password-recovery/sp-results-webterm.png&#34;
    alt=&#34;StartPage results for web terminal container&#34;&gt;
&lt;/figure&gt;
&lt;details class=&#34;admonition note&#34;&gt;&lt;summary class=&#34;admonition-title&#34;&gt;Aside&lt;/summary&gt;
  &lt;p&gt;Docker Hub search is appalling: searching for &lt;code&gt;web terminal&lt;/code&gt; gave me a bunch of &lt;a href=&#34;https://hub.docker.com/search?q=web%20terminal&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;completely unrelated results&lt;/a&gt;. I had to put a dash between the two words &lt;a href=&#34;https://hub.docker.com/search?q=web-terminal&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;to get anywhere&lt;/a&gt;, but then the two first results hadn&amp;rsquo;t been updated in 2 years either&amp;hellip;&lt;/p&gt;
&lt;p&gt;Searching for &lt;code&gt;web shell&lt;/code&gt; and &lt;code&gt;&amp;quot;web shell&amp;quot;&lt;/code&gt; didn&amp;rsquo;t give better results, while &lt;code&gt;web-shell&lt;/code&gt; and &lt;code&gt;webshell&lt;/code&gt; led to very outdated stuff without any description. I can&amp;rsquo;t believe there isn&amp;rsquo;t a reference implementation of this stuff!!&lt;/p&gt;
&lt;p&gt;I also looked up &lt;code&gt;ttyd&lt;/code&gt;, the software used by &lt;code&gt;web-terminal&lt;/code&gt;, and here the first result was fresh from a few days ago; however there was no mention of &lt;em&gt;&amp;ldquo;How to use this with Docker&amp;rdquo;&lt;/em&gt; , so I wasn&amp;rsquo;t sure a simple &lt;code&gt;docker run&lt;/code&gt; would achieve the desired result&amp;hellip; Had I checked its &lt;a href=&#34;https://hub.docker.com/layers/tsl0922/ttyd/alpine/images/sha256-92dd5758ccda91ffc1f113c4c8d8c7407cc236d02c55993dd01d5629fe3a882b?context=explore&amp;amp;tab=vulnerabilities&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Dockerfile&lt;/a&gt;, I would have seen that its &lt;code&gt;ENTRYPOINT&lt;/code&gt;/&lt;code&gt;CMD&lt;/code&gt; was, in fact, starting up the service 🙃&lt;/p&gt;
&lt;/details&gt;
&lt;p&gt;Lo and behold, I took the &amp;ldquo;risk&amp;rdquo; (after checking the image&amp;rsquo;s Dockerfile) and entered the following command in CasaOS Docker CLI interface:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-c&#34; data-lang=&#34;c&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;run&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;v&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;var&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;run&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nl&#34;&gt;sock&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;var&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;run&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;sock&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;p&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;7681&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;7681&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;raonigabriel&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;web&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nl&#34;&gt;terminal&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;latest&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;After setting up the access port in CasaOS interface and confirming everything was okay, I clicked &amp;ldquo;Install&amp;rdquo; and connected to my server&amp;rsquo;s port &lt;code&gt;7681&lt;/code&gt; in a browser&amp;hellip; Success, I was in!&lt;/p&gt;
&lt;p&gt;For the next stage of my plan I ran the following command inspired by &lt;a href=&#34;https://security.stackexchange.com/questions/218355/how-to-execute-a-command-directly-on-the-host-system-through-docker-sock-in-a-do&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;this StackExchange thread&lt;/a&gt;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-c&#34; data-lang=&#34;c&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;run&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;ti&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;--&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;privileged&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;--&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;net&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;--&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;pid&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;--&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;ipc&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;--&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;volume&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/:/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;busybox&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;chroot&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;bin&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;nl&#34;&gt;sh&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;nl&#34;&gt;docker&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;not&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;found&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Crap, I didn&amp;rsquo;t even check that the container had docker installed 🤦 You can tell I really don&amp;rsquo;t know what I am doing 😂&lt;/p&gt;
&lt;p&gt;Of course when I subsequently tried to install docker&amp;hellip;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-py&#34; data-lang=&#34;py&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;root&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;@&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;1&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d0fa4b64c55&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;err&#34;&gt;$&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;apk&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;add&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;fetch&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;main&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;aarch64&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;ERROR&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;main&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;UNTRUSTED&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;signature&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;WARNING&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Ignoring&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;e37b76c2&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;No&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;such&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;file&lt;/span&gt; &lt;span class=&#34;ow&#34;&gt;or&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;directory&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;fetch&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;community&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;aarch64&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;ERROR&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;community&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;UNTRUSTED&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;signature&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;WARNING&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Ignoring&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d022dfc8&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;No&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;such&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;file&lt;/span&gt; &lt;span class=&#34;ow&#34;&gt;or&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;directory&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;ERROR&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;unsatisfiable&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;constraints&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;  &lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;missing&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;):&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;n&#34;&gt;required&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;by&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;world&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;]&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;root&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;@&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;1&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d0fa4b64c55&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;err&#34;&gt;$&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;apk&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;update&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;fetch&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;main&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;aarch64&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;ERROR&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;main&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;UNTRUSTED&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;signature&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;WARNING&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Ignoring&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;e37b76c2&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;No&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;such&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;file&lt;/span&gt; &lt;span class=&#34;ow&#34;&gt;or&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;directory&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;fetch&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;community&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;aarch64&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;ERROR&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;https&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;//&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;dl&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;cdn&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpinelinux&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;org&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;alpine&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;edge&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;community&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;UNTRUSTED&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;signature&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;WARNING&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Ignoring&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;APKINDEX&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d022dfc8&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;tar&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;gz&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;No&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;such&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;file&lt;/span&gt; &lt;span class=&#34;ow&#34;&gt;or&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;directory&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;mi&#34;&gt;2&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;errors&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;36&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;distinct&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;packages&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;available&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;A quick search seems to indicate that the image is &lt;a href=&#34;https://stackoverflow.com/questions/73374745/error-http-dl-4-alpinelinux-org-alpine-edge-testing-untrusted-signature&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;simply too old&lt;/a&gt;. Building an updated image was out of the scope I had set for this experiment, so I paused and took time to think.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;That&amp;rsquo;s when it occurred to me that this &amp;ldquo;nested container&amp;rdquo; approach was completely useless, and would most likely not work since at that point you have the first container&amp;rsquo;s virtualized filesystem namespace acting as a buffer between the host and the DinD container&amp;hellip; Complete misdirection, backing up!&lt;/p&gt;
&lt;h2 id=&#34;the-solution&#34;&gt;&lt;a href=&#34;#the-solution&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;The solution&lt;/h2&gt;&lt;p&gt;After thinking it through some more, I realized one could achieve the desired outcome by simply mounting the host &lt;code&gt;/&lt;/code&gt; read-write as an attached volume 😁&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-c&#34; data-lang=&#34;c&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;run&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;d&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;v&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/:/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;p&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;7681&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;7681&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;raonigabriel&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;web&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nl&#34;&gt;terminal&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;latest&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;em&gt;Et voilà&lt;/em&gt;, I finally had a root shell from which I could chroot into the host and update the user password and/or configure password-less sudo (which amounts to the same). Or really, do (nearly) everything to the host system 😨&lt;/p&gt;
&lt;figure class=&#34;center&#34;&gt;&lt;img src=&#34;https://bastientraverse.com/en/casa-password-recovery/webterm.png&#34;
    alt=&#34;Root shell provided by the web-terminal container&#34;&gt;&lt;figcaption&gt;
      &lt;h4&gt;Root shell provided by the web-terminal container&lt;/h4&gt;
    &lt;/figcaption&gt;
&lt;/figure&gt;
&lt;blockquote&gt;
&lt;p&gt;Initially I thought it would be necessary to use a &lt;a href=&#34;https://docs.docker.com/engine/reference/run/#runtime-privilege-and-linux-capabilities&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;privileged&lt;/a&gt; container, but trying it showed that wasn&amp;rsquo;t the case. I guess it&amp;rsquo;s because I was only editing files/using regular utilites, and not trying to create new devices/nodes etc.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id=&#34;the-solution-simplified&#34;&gt;&lt;a href=&#34;#the-solution-simplified&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;The solution: simplified&lt;/h2&gt;&lt;p&gt;This is what happens when you don&amp;rsquo;t know your tools enough&amp;hellip; You miss very obvious pathways that lead to simpler solutions 😁&lt;/p&gt;
&lt;p&gt;Indeed, there is no need to install a third-party container. It is enough to add the &lt;code&gt;/:/host&lt;/code&gt; volume to an existing app installed from CasaOS official App Store (&lt;em&gt;e.g.&lt;/em&gt; NextCloud), and  after making sure in its settings it runs with the root &lt;code&gt;UID&lt;/code&gt;/&lt;code&gt;GID&lt;/code&gt;, we can use the interface to connect the container&amp;rsquo;s console!&lt;/p&gt;
&lt;figure class=&#34;center&#34;&gt;&lt;img src=&#34;https://bastientraverse.com/en/casa-password-recovery/casa-nc-root-shell.png&#34;
    alt=&#34;Root shell inside nextcloud container&#34;&gt;&lt;figcaption&gt;
      &lt;h4&gt;Root shell inside nextcloud container&lt;/h4&gt;
    &lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;And that is the Easy Way© to get a root shell on your server using containers!&lt;/p&gt;
&lt;h2 id=&#34;trying-to-refine-the-solution&#34;&gt;&lt;a href=&#34;#trying-to-refine-the-solution&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Trying to refine the solution&lt;/h2&gt;&lt;p&gt;Now that I was there, I felt like I should have been able to use a simple &lt;code&gt;busybox&lt;/code&gt; image to execute a command non-interactively directly from &lt;code&gt;docker run&lt;/code&gt;/Compose file, eliminating the need to find an image that exposes a web service or to connect to the container&amp;rsquo;s console.&lt;/p&gt;
&lt;p&gt;After a bit of fiddling, I came up with the following invocation:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-c&#34; data-lang=&#34;c&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;docker&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;run&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;v&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;etc&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;nl&#34;&gt;sudoers&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;etc&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;sudoers&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;busybox&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;bin&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;sh&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;c&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;echo&lt;/span&gt; &lt;span class=&#34;err&#34;&gt;&amp;#39;&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;sudo&lt;/span&gt;  &lt;span class=&#34;n&#34;&gt;ALL&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;ALL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;nl&#34;&gt;NOPASSWD&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;ALL&lt;/span&gt;&lt;span class=&#34;err&#34;&gt;&amp;#39;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;&amp;gt;&amp;gt;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;host&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;etc&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;/&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;sudoers&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;But CasaOS interface constantly threw an error. Probably the redirection in the command, but no amount of quoting led me to a successful run.&lt;/p&gt;
&lt;p&gt;At that point I threw the towel in: I had recovered access to my sudo access and learnt quite a few things along the way. Time to wrap up.&lt;/p&gt;
&lt;h2 id=&#34;takeways&#34;&gt;&lt;a href=&#34;#takeways&#34; class=&#34;headerlink anchor&#34;&gt;&lt;i class=&#34;iconfont icon-link&#34;&gt;&lt;/i&gt;&lt;/a&gt;Takeways&lt;/h2&gt;&lt;ul&gt;
&lt;li&gt;Docker default security story is scary: because the daemon runs as root by default, the mere ability to run containers (even without &lt;code&gt;--privileged&lt;/code&gt;) and mount any desired host path as a volume gives &lt;a href=&#34;https://stackoverflow.com/a/32192369&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;root-equivalent status&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Due to this, access to CasaOS interface is equivalent to root access on the server&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;That&amp;rsquo;s all folks, thanks for reading this account I hope you enjoyed!&lt;/p&gt;
&lt;div class=&#34;footnotes&#34; role=&#34;doc-endnotes&#34;&gt;
&lt;hr&gt;
&lt;ol&gt;
&lt;li id=&#34;fn:1&#34;&gt;
&lt;p&gt;See &lt;em&gt;e.g.&lt;/em&gt; &lt;a href=&#34;https://gcore.com/learning/how-to-reset-password-in-linux/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;https://gcore.com/learning/how-to-reset-password-in-linux/&lt;/a&gt;&amp;#160;&lt;a href=&#34;#fnref:1&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
</description>
    </item>
    
  </channel>
</rss>
