{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "My thoughts on the pang-wang",
  "home_page_url": "https://pype.dev/linux/",
  "feed_url": "https://pype.dev/linux/feed.json",
  "description": "My thoughts and streams of consciousness organized into barely coherent posts about things",
  "authors": [
    {
      "name": "Nic Payne"
    }
  ],
  "items": [
    {
      "id": "https://pype.dev/thoughts-745/",
      "url": "https://pype.dev/thoughts-745/",
      "title": "💭 Tyblog | systemd has been a complete, utter, unmitigated success",
      "content_html": "\u003ca href=\"https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Tyblog | systemd has been a complete, utter, unmitigated success\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\u003cp\u003eHere\u0026rsquo;s my thought on \u003ca href=\"https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\"\u003eTyblog | systemd has been a complete, utter, unmitigated success\u003c/a\u003e\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eI found this post on systemd this morning, and although I\u0026rsquo;ve been a Linux user for around 6 years now, there\u0026rsquo;s some levels of it that are pretty foreign to me. One of the things I never got was the drama around systemd - but that\u0026rsquo;s because I wasn\u0026rsquo;t around in the beforefore times, I don\u0026rsquo;t use cron THAT MUCH, and I\u0026rsquo;ve only had to setup a few systemd unit files - not enough to generate a real opinion on it.\nBut lately I\u0026rsquo;m looking into more automation at home - and some stuff is fun to put into an overkill of a platform for a homelab, like temporal, but some stuff should probably be run in more hardened ways (backups for example) - so getting a little download this morning on systemd from a clearly seasoned Linux user is a nice addition to my hot cup of coffee.\u003c/p\u003e\n\u003chr\u003e\n\u003cdiv class=\"admonition note\"\u003e\n\u003cp class=\"admonition-title\"\u003eNote\u003c/p\u003e\n\u003cp\u003eThis is one of [[ my-thoughts ]]. I picked this up from \u003ca href=\"https://waylonwalker.com\"\u003eWaylon Walker\u003c/a\u003e(\u003ca href=\"https://thoughts.waylonwalker.com\"\u003ehttps://thoughts.waylonwalker.com\u003c/a\u003e). It\u0026rsquo;s a short note that I make about someone else\u0026rsquo;s content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\" data-preview=\"My thoughts are found at my thoughts feed\"\u003eThoughts\u003c/a\u003e\u003c/p\u003e\n\u003c/div\u003e\n",
      "content_text": "\n\u003ca href=\"https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Tyblog | systemd has been a complete, utter, unmitigated success\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\nHere's my thought on \u003ca href=\"https://blog.tjll.net/the-systemd-revolution-has-been-a-success/\"\u003eTyblog | systemd has been a complete, utter, unmitigated success\u003c/a\u003e\n\n---\n\nI found this post on systemd this morning, and although I've been a Linux user for around 6 years now, there's some levels of it that are pretty foreign to me. One of the things I never got was the drama around systemd - but that's because I wasn't around in the beforefore times, I don't use cron THAT MUCH, and I've only had to setup a few systemd unit files - not enough to generate a real opinion on it.\nBut lately I'm looking into more automation at home - and some stuff is fun to put into an overkill of a platform for a homelab, like temporal, but some stuff should probably be run in more hardened ways (backups for example) - so getting a little download this morning on systemd from a clearly seasoned Linux user is a nice addition to my hot cup of coffee.\n\n---\n\n!!! note\n    This is one of [[ my-thoughts ]]. I picked this up from [Waylon Walker](https://waylonwalker.com)(https://thoughts.waylonwalker.com). It's a short note that I make about someone else's content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\"\u003eThoughts\u003c/a\u003e\n",
      "summary": "I found this post on systemd this morning, and although I've been a Linux user for around 6 years now, there's some leve",
      "date_published": "2025-07-11T11:00:54Z",
      "date_modified": "2025-07-11T11:00:54Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "systemd",
        "linux",
        "blog",
        "thoughts"
      ]
    },
    {
      "id": "https://pype.dev/thoughts-735/",
      "url": "https://pype.dev/thoughts-735/",
      "title": "💭 Self-Hosting A Cluster On Old Phones | Hackaday",
      "content_html": "\u003ca href=\"https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Self-Hosting A Cluster On Old Phones | Hackaday\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\u003cp\u003eHere\u0026rsquo;s my thought on \u003ca href=\"https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\"\u003eSelf-Hosting A Cluster On Old Phones | Hackaday\u003c/a\u003e\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eCame across a blog and article on using a mobile OS to self-host a cluster on old phones\u0026hellip; I happen to keep several old android phones lying around and although I\u0026rsquo;m not presently super interested in figuring out an android/arm based homelab, I am excited for the next coming years when I\u0026rsquo;m sure it\u0026rsquo;ll only get easier, phones will only be more powerful, and perhaps we\u0026rsquo;ll be running full blown CV pipeline in k8s clusters running on Pixel devices!\u003c/p\u003e\n\u003chr\u003e\n\u003cdiv class=\"admonition note\"\u003e\n\u003cp class=\"admonition-title\"\u003eNote\u003c/p\u003e\n\u003cp\u003eThis is one of [[ my-thoughts ]]. I picked this up from \u003ca href=\"https://waylonwalker.com\"\u003eWaylon Walker\u003c/a\u003e(\u003ca href=\"https://thoughts.waylonwalker.com\"\u003ehttps://thoughts.waylonwalker.com\u003c/a\u003e). It\u0026rsquo;s a short note that I make about someone else\u0026rsquo;s content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\" data-preview=\"My thoughts are found at my thoughts feed\"\u003eThoughts\u003c/a\u003e\u003c/p\u003e\n\u003c/div\u003e\n",
      "content_text": "\n\u003ca href=\"https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Self-Hosting A Cluster On Old Phones | Hackaday\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\nHere's my thought on \u003ca href=\"https://hackaday.com/2025/04/09/self-hosting-a-cluster-on-old-phones/?ref=dailydev\"\u003eSelf-Hosting A Cluster On Old Phones | Hackaday\u003c/a\u003e\n\n---\n\nCame across a blog and article on using a mobile OS to self-host a cluster on old phones... I happen to keep several old android phones lying around and although I'm not presently super interested in figuring out an android/arm based homelab, I am excited for the next coming years when I'm sure it'll only get easier, phones will only be more powerful, and perhaps we'll be running full blown CV pipeline in k8s clusters running on Pixel devices!\n\n---\n\n!!! note\n    This is one of [[ my-thoughts ]]. I picked this up from [Waylon Walker](https://waylonwalker.com)(https://thoughts.waylonwalker.com). It's a short note that I make about someone else's content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\"\u003eThoughts\u003c/a\u003e\n",
      "summary": "Came across a blog and article on using a mobile OS to self-host a cluster on old phones... I happen to keep several old",
      "date_published": "2025-07-06T11:30:17Z",
      "date_modified": "2025-07-06T11:30:17Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "k8s",
        "linux",
        "android",
        "homelab",
        "thoughts"
      ]
    },
    {
      "id": "https://pype.dev/thoughts-670/",
      "url": "https://pype.dev/thoughts-670/",
      "title": "💭 Linux Explained: What is The Linux Kernel? - YouTube",
      "content_html": "\u003ca href=\"https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Linux Explained: What is The Linux Kernel? - YouTube\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\u003cp\u003eHere\u0026rsquo;s my thought on \u003ca href=\"https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\"\u003eLinux Explained: What is The Linux Kernel? - YouTube\u003c/a\u003e\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eI\u0026rsquo;m getting sucked into the Linux is a kernel not an operating system crowd because tonight I realized I couldn\u0026rsquo;t describe what a kernel is so I YouTubeda few things and before you know it you joined a decades old war before finishing loading the dishwasher\u003c/p\u003e\n\u003chr\u003e\n\u003cdiv class=\"admonition note\"\u003e\n\u003cp class=\"admonition-title\"\u003eNote\u003c/p\u003e\n\u003cp\u003eThis is one of [[ my-thoughts ]]. I picked this up from \u003ca href=\"https://waylonwalker.com\"\u003eWaylon Walker\u003c/a\u003e(\u003ca href=\"https://thoughts.waylonwalker.com\"\u003ehttps://thoughts.waylonwalker.com\u003c/a\u003e). It\u0026rsquo;s a short note that I make about someone else\u0026rsquo;s content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\" data-preview=\"My thoughts are found at my thoughts feed\"\u003eThoughts\u003c/a\u003e\u003c/p\u003e\n\u003c/div\u003e\n",
      "content_text": "\n\u003ca href=\"https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\"\u003e\n    \u003cimg\n        src=\"https://shots.wayl.one/shot/?url=https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\u0026height=450\u0026width=800\u0026scaled_width=800\u0026scaled_height=450\u0026selectors=\"\n        alt=\"shot of post - Linux Explained: What is The Linux Kernel? - YouTube\"\n        height=450\n        width=800\n    \u003e\n\u003c/a\u003e\n\nHere's my thought on \u003ca href=\"https://www.youtube.com/watch?si=CFRBAdjtI0x7Pmj7\u0026v=pJ607nDnyE0\u0026feature=youtu.be\"\u003eLinux Explained: What is The Linux Kernel? - YouTube\u003c/a\u003e\n\n---\n\nI'm getting sucked into the Linux is a kernel not an operating system crowd because tonight I realized I couldn't describe what a kernel is so I YouTubeda few things and before you know it you joined a decades old war before finishing loading the dishwasher\n\n---\n\n!!! note\n    This is one of [[ my-thoughts ]]. I picked this up from [Waylon Walker](https://waylonwalker.com)(https://thoughts.waylonwalker.com). It's a short note that I make about someone else's content online.  Learn more about the process \u003ca href=\"/thoughts/\" class=\"wikilink\" data-title=\"Thoughts\" data-description=\"My thoughts are found at my thoughts feed\" data-date=\"2025-06-09\"\u003eThoughts\u003c/a\u003e\n",
      "summary": "I'm getting sucked into the Linux is a kernel not an operating system crowd because tonight I realized I couldn't descri",
      "date_published": "2025-06-07T11:28:18Z",
      "date_modified": "2025-06-07T11:28:18Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "youtube",
        "kernel",
        "thoughts"
      ]
    },
    {
      "id": "https://pype.dev/i-was-wrecked-by-a-weird-combo-of-and-e/",
      "url": "https://pype.dev/i-was-wrecked-by-a-weird-combo-of-and-e/",
      "title": "I was wrecked by a weird combo of » and -e",
      "content_html": "\u003ch2 id=\"tl-dr\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eTL;DR\u003c/span\u003e \u003ca href=\"#tl-dr\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eIf state matters then check it in the beginning or handle it on a failure\u0026hellip; Let me explain\u003c/p\u003e\n\u003cp\u003eI ran into some trouble recently \u003cem\u003ealmost\u003c/em\u003e losing some encrypted data\u0026hellip; Now\nthis would be the second time I\u0026rsquo;ve had that happen, so I\u0026rsquo;m going to write a\nlittle bit about it now that I figured it out\u003c/p\u003e\n\u003ch2 id=\"the-stage\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eThe Stage\u003c/span\u003e \u003ca href=\"#the-stage\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eHere\u0026rsquo;s the scenario - I use \u003ccode\u003eansible-vault\u003c/code\u003e to keep some sensitive data in a\nfew public repos, and I keep the keys I use in Bitwarden Secrets Manager.\u003c/p\u003e\n\u003cp\u003eI use \u003ccode\u003ejust\u003c/code\u003e as a command runner and have common \u003ccode\u003ejust encrypt\u003c/code\u003e and \u003ccode\u003ejust decrypt\u003c/code\u003e recipes throughout many justfiles. It might look something like this\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eget-vault-key:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    bws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eencrypt:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"c1\"\u003e#!/bin/bash\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"nb\"\u003eset\u003c/span\u003e +e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    just get-vault-key \u0026gt; key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault encrypt ./secret-file --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault encrypt ./secret-file2 --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    rm key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003edecrypt:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"c1\"\u003e#!/bin/bash\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"nb\"\u003eset\u003c/span\u003e +e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    just get-vault-key \u0026gt; key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault decrypt ./secret-file --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault decrypt ./secret-file2 --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    rm key\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003ch2 id=\"spoiler\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eSpoiler\u003c/span\u003e \u003ca href=\"#spoiler\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eAbove is a good example of the 2 recipes, but prior to this morning they looked like this\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eget-vault-key:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    bws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"c1\"\u003e# BAD EXAMPLES! DO NOT DO THIS\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eencrypt:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"nb\"\u003eset\u003c/span\u003e -e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    just get-vault-key \u0026gt;\u0026gt; key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault encrypt ./secret-file --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault encrypt ./secret-file2 --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    rm key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003edecrypt:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    \u003cspan class=\"nb\"\u003eset\u003c/span\u003e -e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    just get-vault-key \u0026gt;\u0026gt; key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault decrypt ./secret-file --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    ansible-vault decrypt ./secret-file2 --vault-password-file key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e    rm key\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003ch2 id=\"problem\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eProblem\u003c/span\u003e \u003ca href=\"#problem\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eSo here\u0026rsquo;s the story - in real life I started using distrobox when I ran into\nthis and I thought it was an issue with different versions of ansible installed\nin distrobox and on my desktop. After a few more odd deployment workflows I\nthink I\u0026rsquo;ve determined that the real problem is that \u003ccode\u003e\u0026gt;\u0026gt;\u003c/code\u003e appends to a file (see\nthe issue yet?), but if my recipes fail (say I try to encrypt an already\nencrypted file) then the command exits but what\u0026rsquo;s left on my disk? \u003ccode\u003ekey\u003c/code\u003e is\nstill there\u0026hellip; and the next time I go to run a command I\u0026rsquo;ll echo the real key\nto the \u003ccode\u003ekey\u003c/code\u003e file again and if I called \u003ccode\u003eencrypt\u003c/code\u003e when the first or more files\nin the list were \u003ccode\u003edecrypted\u003c/code\u003e then they\u0026rsquo;ll be encrypted not with my key, but\nwith my key repeated as many times as I ran a command with \u003ccode\u003ejust get-vault-key \u0026gt;\u0026gt; key\u003c/code\u003e\nbefore ever removing the key file!\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ cat secret-file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eDanger, Will Robinson\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ just encrypt\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ebws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eEncryption successful\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ cat secret-file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"nv\"\u003e$ANSIBLE_VAULT\u003c/span\u003e\u003cspan class=\"p\"\u003e;\u003c/span\u003e1.1\u003cspan class=\"p\"\u003e;\u003c/span\u003eAES256\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"m\"\u003e39616332393662346639633030633766666336323939346138633238626239363733316431333737\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e6463663763366434376437303335643431663431326135300a636261663636336139323033316232\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"m\"\u003e37666439383131393631333332353731633661396431633834326432363936613331623135666565\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e6364363039663933620a326563323931643632323031396664646363613636613562366166386439\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"m\"\u003e63653661653037393538356461323239396630643338393231306163343964623866\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ just decrypt\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ebws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eDecryption successful\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ cat secret-file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eDanger, Will Robinson\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eSo as you can see, I have \u003ccode\u003esecret-file\u003c/code\u003e here, and I can encrypt and decrypt\njust fine. But if I have that \u003ccode\u003e\u0026gt;\u0026gt;\u003c/code\u003e in the recipe, add a second file, and a\nfailure in a command - well then I\u0026rsquo;ll start getting confused\u0026hellip;\u003c/p\u003e\n\u003cp\u003eFollow along with the workflow of adding a file that I\u0026rsquo;ll need encrypted\u003c/p\u003e\n\u003cblockquote\u003e\n\u003cp\u003eOnly secret-file is in the just recipe here - I add secret-file2 after\u003c/p\u003e\n\u003c/blockquote\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ just decrypt\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ebws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eERROR! input is not vault encrypted data. /var/home/nic/projects/personal/pype.dev/secret-file is not a vault encrypted file \u003cspan class=\"k\"\u003efor\u003c/span\u003e /var/home/nic/projects/personal/pype.dev/secret-file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eerror: Recipe \u003cspan class=\"sb\"\u003e`\u003c/span\u003edecrypt\u003cspan class=\"sb\"\u003e`\u003c/span\u003e failed with \u003cspan class=\"nb\"\u003eexit\u003c/span\u003e code \u003cspan class=\"m\"\u003e1\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e✗ \u003cspan class=\"nb\"\u003eecho\u003c/span\u003e \u003cspan class=\"s2\"\u003e\u0026#34;Good - secret-file is already decrypted! So lets add another file\u0026#34;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eGood - secret-file is already decrypted! So lets add another file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ \u003cspan class=\"nb\"\u003eecho\u003c/span\u003e \u003cspan class=\"s2\"\u003e\u0026#34;Foo Bar Bam Baz\u0026#34;\u003c/span\u003e \u0026gt; secret-file2                                    \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ \u003cspan class=\"nb\"\u003eecho\u003c/span\u003e \u003cspan class=\"s2\"\u003e\u0026#34;Added secret-file2 to my Just recipes\u0026#34;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eAdded secret-file2 to my Just recipes\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ just encrypt\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ebws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eEncryption successful\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eEncryption successful\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ just decrypt\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ebws secret get \u003cspan class=\"nv\"\u003e$HOMELAB_BOT_VAULT_KEY_ID\u003c/span\u003e  \u003cspan class=\"p\"\u003e|\u003c/span\u003e jq -r \u003cspan class=\"s1\"\u003e\u0026#39;.value\u0026#39;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eERROR! Decryption failed \u003cspan class=\"o\"\u003e(\u003c/span\u003eno vault secrets were found that could decrypt\u003cspan class=\"o\"\u003e)\u003c/span\u003e on /var/home/nic/projects/personal/pype.dev/secret-file \u003cspan class=\"k\"\u003efor\u003c/span\u003e /var/home/nic/projects/personal/pype.dev/secret-file\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eerror: Recipe \u003cspan class=\"sb\"\u003e`\u003c/span\u003edecrypt\u003cspan class=\"sb\"\u003e`\u003c/span\u003e failed with \u003cspan class=\"nb\"\u003eexit\u003c/span\u003e code \u003cspan class=\"m\"\u003e1\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003enic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10\u003cspan class=\"o\"\u003e(\u003c/span\u003epype-dev\u003cspan class=\"o\"\u003e)\u003c/span\u003e   \u003cspan class=\"o\"\u003e(\u003c/span\u003edev\u003cspan class=\"o\"\u003e)\u003c/span\u003e 󰒄 \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e✗ \u003cspan class=\"nb\"\u003eecho\u003c/span\u003e \u003cspan class=\"s2\"\u003e\u0026#34;Oh no!\u0026#34;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eSo what happened?\u003c/p\u003e\n\u003cp\u003eRecall that my recipes originally had \u003ccode\u003eset -e\u003c/code\u003e at the top and used \u003ccode\u003e\u0026gt;\u0026gt;\u003c/code\u003e to cat\nmy secret to a file \u003ccode\u003ekey\u003c/code\u003e. Well, when the fir| decryption recipe failed the\n\u003ccode\u003ekey\u003c/code\u003e file was left behind. Then when I went to encrypt both of my files the\nrecipe got the key again and made a keyfile like this:\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003esecretKey\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003esecretKey\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eThe encryption recipe encrypted the files with this key, removed the key file,\nand then the next decryption recipe failed because when it got the key and made\nthe file it looked like\u003c/p\u003e\n\u003cpre\u003e\u003ccode\u003esecretKey\n\u003c/code\u003e\u003c/pre\u003e\n\u003cp\u003eSo the solution in the end is to remake the \u003ccode\u003ekey\u003c/code\u003e file every time (\u003ccode\u003e\u0026gt;\u003c/code\u003e instead\nof \u003ccode\u003e\u0026gt;\u0026gt;\u003c/code\u003e), or check if it exists, or handle the error when the recipe fails, or\njust keep going (\u003ccode\u003eset +e\u003c/code\u003e)\u003c/p\u003e\n\u003ch2 id=\"fin\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eFin\u003c/span\u003e \u003ca href=\"#fin\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eAnd that\u0026rsquo;s how I lost some secrets in my homelab once, and how I almost lost a\nsecond time if I hadn\u0026rsquo;t noticed the \u003ccode\u003ekey\u003c/code\u003e file in my file tree\u003c/p\u003e\n",
      "content_text": "\n## TL;DR\n\nIf state matters then check it in the beginning or handle it on a failure... Let me explain\n\nI ran into some trouble recently _almost_ losing some encrypted data... Now\nthis would be the second time I've had that happen, so I'm going to write a\nlittle bit about it now that I figured it out\n\n## The Stage\n\nHere's the scenario - I use `ansible-vault` to keep some sensitive data in a\nfew public repos, and I keep the keys I use in Bitwarden Secrets Manager.\n\nI use `just` as a command runner and have common `just encrypt` and `just\ndecrypt` recipes throughout many justfiles. It might look something like this\n\n```bash\n\nget-vault-key:\n    bws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\n\nencrypt:\n    #!/bin/bash\n    set +e\n    just get-vault-key \u003e key\n    ansible-vault encrypt ./secret-file --vault-password-file key\n    ansible-vault encrypt ./secret-file2 --vault-password-file key\n    rm key\n\ndecrypt:\n    #!/bin/bash\n    set +e\n    just get-vault-key \u003e key\n    ansible-vault decrypt ./secret-file --vault-password-file key\n    ansible-vault decrypt ./secret-file2 --vault-password-file key\n    rm key\n```\n\n## Spoiler\n\nAbove is a good example of the 2 recipes, but prior to this morning they looked like this\n\n```bash\n\nget-vault-key:\n    bws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\n\n# BAD EXAMPLES! DO NOT DO THIS\n\nencrypt:\n    set -e\n    just get-vault-key \u003e\u003e key\n    ansible-vault encrypt ./secret-file --vault-password-file key\n    ansible-vault encrypt ./secret-file2 --vault-password-file key\n    rm key\n\ndecrypt:\n    set -e\n    just get-vault-key \u003e\u003e key\n    ansible-vault decrypt ./secret-file --vault-password-file key\n    ansible-vault decrypt ./secret-file2 --vault-password-file key\n    rm key\n```\n\n## Problem\n\nSo here's the story - in real life I started using distrobox when I ran into\nthis and I thought it was an issue with different versions of ansible installed\nin distrobox and on my desktop. After a few more odd deployment workflows I\nthink I've determined that the real problem is that `\u003e\u003e` appends to a file (see\nthe issue yet?), but if my recipes fail (say I try to encrypt an already\nencrypted file) then the command exits but what's left on my disk? `key` is\nstill there... and the next time I go to run a command I'll echo the real key\nto the `key` file again and if I called `encrypt` when the first or more files\nin the list were `decrypted` then they'll be encrypted not with my key, but\nwith my key repeated as many times as I ran a command with `just get-vault-key \u003e\u003e key`\nbefore ever removing the key file!\n\n```bash\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ cat secret-file\nDanger, Will Robinson\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ just encrypt\nbws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\nEncryption successful\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ cat secret-file\n$ANSIBLE_VAULT;1.1;AES256\n39616332393662346639633030633766666336323939346138633238626239363733316431333737\n6463663763366434376437303335643431663431326135300a636261663636336139323033316232\n37666439383131393631333332353731633661396431633834326432363936613331623135666565\n6364363039663933620a326563323931643632323031396664646363613636613562366166386439\n63653661653037393538356461323239396630643338393231306163343964623866\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ just decrypt\nbws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\nDecryption successful\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ cat secret-file\nDanger, Will Robinson\n```\n\nSo as you can see, I have `secret-file` here, and I can encrypt and decrypt\njust fine. But if I have that `\u003e\u003e` in the recipe, add a second file, and a\nfailure in a command - well then I'll start getting confused...\n\nFollow along with the workflow of adding a file that I'll need encrypted\n\n\u003e Only secret-file is in the just recipe here - I add secret-file2 after\n\n```bash\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ just decrypt\nbws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\nERROR! input is not vault encrypted data. /var/home/nic/projects/personal/pype.dev/secret-file is not a vault encrypted file for /var/home/nic/projects/personal/pype.dev/secret-file\nerror: Recipe `decrypt` failed with exit code 1\n\nnic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10(pype-dev)   (dev) 󰒄 \n✗ echo \"Good - secret-file is already decrypted! So lets add another file\"\nGood - secret-file is already decrypted! So lets add another file\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ echo \"Foo Bar Bam Baz\" \u003e secret-file2                                    \n\nnic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ echo \"Added secret-file2 to my Just recipes\"\nAdded secret-file2 to my Just recipes\n\nnic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ just encrypt\nbws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\nEncryption successful\nEncryption successful\n\nnic in pype.dev   main   ×2  ×3  ×7 via   v3.11.10(pype-dev)   (dev) 󰒄 \n❯ just decrypt\nbws secret get $HOMELAB_BOT_VAULT_KEY_ID  | jq -r '.value'\nERROR! Decryption failed (no vault secrets were found that could decrypt) on /var/home/nic/projects/personal/pype.dev/secret-file for /var/home/nic/projects/personal/pype.dev/secret-file\nerror: Recipe `decrypt` failed with exit code 1\n\nnic in pype.dev   main   ×2  ×3  ×8 via   v3.11.10(pype-dev)   (dev) 󰒄 \n✗ echo \"Oh no!\"\n```\n\nSo what happened?\n\nRecall that my recipes originally had `set -e` at the top and used `\u003e\u003e` to cat\nmy secret to a file `key`. Well, when the fir| decryption recipe failed the\n`key` file was left behind. Then when I went to encrypt both of my files the\nrecipe got the key again and made a keyfile like this:\n\n```bash\nsecretKey\nsecretKey\n```\n\nThe encryption recipe encrypted the files with this key, removed the key file,\nand then the next decryption recipe failed because when it got the key and made\nthe file it looked like\n\n```\nsecretKey\n```\n\nSo the solution in the end is to remake the `key` file every time (`\u003e` instead\nof `\u003e\u003e`), or check if it exists, or handle the error when the recipe fails, or\njust keep going (`set +e`)\n\n## Fin\n\nAnd that's how I lost some secrets in my homelab once, and how I almost lost a\nsecond time if I hadn't noticed the `key` file in my file tree\n",
      "summary": "If state matters then check it in the beginning or handle it on a failure... Let me explain",
      "date_published": "2025-04-23T08:44:59Z",
      "date_modified": "2025-04-23T08:44:59Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "cli",
        "tech"
      ]
    },
    {
      "id": "https://pype.dev/smb-with-zfs-on-ubuntu/",
      "url": "https://pype.dev/smb-with-zfs-on-ubuntu/",
      "title": "SMB with ZFS on Ubuntu",
      "content_html": "\u003cp\u003esudo apt-get install -y samba \\ then set sharesmb=on \\ chown the user \\ smbpasswd \u003cuser\u003e -a \\ then mount with user/password from other machine\u003c/p\u003e\n",
      "content_text": "\nsudo apt-get install -y samba \\\\ then set sharesmb=on \\\\ chown the user \\\\ smbpasswd \u003cuser\u003e -a \\\\ then mount with user/password from other machine\n",
      "summary": "sudo apt-get install -y samba \\\\ then set sharesmb=on \\\\ chown the user \\\\ smbpasswd -a \\\\ then mount with user/password from other machine",
      "date_published": "2025-02-20T09:18:35Z",
      "date_modified": "2025-02-20T09:18:35Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "zfs",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/jellyfin-container-updates-for-hwe-amd/",
      "url": "https://pype.dev/jellyfin-container-updates-for-hwe-amd/",
      "title": "Jellyfin container updates for HWE + AMD",
      "content_html": "\u003cp\u003eI use LSIO Jelyfin container for the easy addon they provide for AMD GPUs but I couldn\u0026rsquo;t get trickplay to work with HWE\u0026hellip;\u003c/p\u003e\n\u003cp\u003eThere was almost NOTHING on the internet about the error, and all the threads were about BSD systems\u0026hellip;\u003c/p\u003e\n\u003cp\u003eThankfully someone posted \u003ca href=\"https://forum.jellyfin.org/t-jellyfin-amd-docker\"\u003eon the formum here\u003c/a\u003e but the only answer was to literally upgrade stuff in the container\u0026hellip;\u003c/p\u003e\n\u003cp\u003eSomeday maybe I\u0026rsquo;ll build off of LSIO to add this, but until then I shell\u0026rsquo;d in and homelab\u0026rsquo;d the hell out of it\u003c/p\u003e\n\u003cblockquote\u003e\n\u003cp\u003eTHIS IS INSIDE THE CONTAINER - I use Portianer to make it easy\u003c/p\u003e\n\u003c/blockquote\u003e\n\u003cpre\u003e\u003ccode\u003e\napt update \u0026amp;\u0026amp; apt install -y curl gpg\n\nmkdir -p /etc/apt/keyrings\n\ncurl -fsSL https://repo.radeon.com/rocm/rocm.gpg.key | gpg --dearmor -o /etc/apt/keyrings/rocm.gpg\n\ncat \u0026lt;\u0026lt;EOF | tee /etc/apt/sources.list.d/rocm.sources\n\nTypes: deb\n\nURIs: https://repo.radeon.com/rocm/apt/latest\n\nSuites: ubuntu\n\nComponents: main\n\nArchitectures: amd64\n\nSigned-By: /etc/apt/keyrings/rocm.gpg\n\nEOF\n\napt update \u0026amp;\u0026amp; apt install -y rocm-opencl-runtime\n\u003c/code\u003e\u003c/pre\u003e\n",
      "content_text": "\nI use LSIO Jelyfin container for the easy addon they provide for AMD GPUs but I couldn't get trickplay to work with HWE... \n\nThere was almost NOTHING on the internet about the error, and all the threads were about BSD systems...\n\nThankfully someone posted [on the formum here](https://forum.jellyfin.org/t-jellyfin-amd-docker) but the only answer was to literally upgrade stuff in the container...\n\nSomeday maybe I'll build off of LSIO to add this, but until then I shell'd in and homelab'd the hell out of it\n\n\u003e THIS IS INSIDE THE CONTAINER - I use Portianer to make it easy\n\n```\n\napt update \u0026\u0026 apt install -y curl gpg\n\nmkdir -p /etc/apt/keyrings\n\ncurl -fsSL https://repo.radeon.com/rocm/rocm.gpg.key | gpg --dearmor -o /etc/apt/keyrings/rocm.gpg\n\ncat \u003c\u003cEOF | tee /etc/apt/sources.list.d/rocm.sources\n\nTypes: deb\n\nURIs: https://repo.radeon.com/rocm/apt/latest\n\nSuites: ubuntu\n\nComponents: main\n\nArchitectures: amd64\n\nSigned-By: /etc/apt/keyrings/rocm.gpg\n\nEOF\n\napt update \u0026\u0026 apt install -y rocm-opencl-runtime\n```\n",
      "summary": "I use LSIO Jelyfin container for the easy addon they provide for AMD GPUs but I couldn't get trickplay to work with HWE...",
      "date_published": "2024-12-14T11:27:15Z",
      "date_modified": "2024-12-14T11:27:15Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "docker",
        "linux",
        "homelab",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/rsync-like-a-pro/",
      "url": "https://pype.dev/rsync-like-a-pro/",
      "title": "rsync like a pro",
      "content_html": "\u003cp\u003eI am moving a hefty amount of data to a new ZFS pool due to some corruption and I want to avoid using \u003ccode\u003ezfs send/recv\u003c/code\u003e for this just to make sure I don\u0026rsquo;t propagate any corrupted data to my new pool.\u003c/p\u003e\n\u003cp\u003eI\u0026rsquo;ve used \u003ccode\u003ersync\u003c/code\u003e for simple things before but I needed this to be a little smarter and I wanted to see simple progress without flooding my terminal with a billion filenames.\u003c/p\u003e\n\u003ch2 id=\"tldr\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eTLDR\u003c/span\u003e \u003ca href=\"#tldr\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eTLDR:\n\u003ccode\u003ersync -aHAX --chmod=Da+s --info=progress2 --inplace --exclude='encrypted/docker/frigate-media' /tank/ /harbor/\u003c/code\u003e\u003c/p\u003e\n\u003ch2 id=\"explanation\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eExplanation\u003c/span\u003e \u003ca href=\"#explanation\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003e-aHAX: Preserves attributes (archive mode, hard links, ACLs, extended attributes).\n\u0026ndash;chmod=Da+s: Ensures the setgid bit is applied to directories.\n\u0026ndash;info=progress2: Provides detailed progress information, including overall data transfer stats.\n\u0026ndash;inplace: Writes directly to the destination file, avoiding temporary files (useful for large files).\n\u0026ndash;exclude=\u0026lsquo;encrypted/\u003ca href=\"/docker/\" class=\"glossary-term\" title=\"docker - container runtime\" data-hover-title=\"docker\"\u003edocker\u003c/a\u003e/frigate-media\u0026rsquo;: Excludes the specified path (relative to the /tank root).\n/tank/ /harbor/: Ensures the contents of /tank are copied directly into /harbor.\u003c/p\u003e\n",
      "content_text": "\n\nI am moving a hefty amount of data to a new ZFS pool due to some corruption and I want to avoid using `zfs send/recv` for this just to make sure I don't propagate any corrupted data to my new pool.\n\nI've used `rsync` for simple things before but I needed this to be a little smarter and I wanted to see simple progress without flooding my terminal with a billion filenames.\n\n## TLDR\nTLDR: \n`rsync -aHAX --chmod=Da+s --info=progress2 --inplace --exclude='encrypted/docker/frigate-media' /tank/ /harbor/`\n\n## Explanation\n\n-aHAX: Preserves attributes (archive mode, hard links, ACLs, extended attributes).\n--chmod=Da+s: Ensures the setgid bit is applied to directories.\n--info=progress2: Provides detailed progress information, including overall data transfer stats.\n--inplace: Writes directly to the destination file, avoiding temporary files (useful for large files).\n--exclude='encrypted/docker/frigate-media': Excludes the specified path (relative to the /tank root).\n/tank/ /harbor/: Ensures the contents of /tank are copied directly into /harbor.\n\n\n",
      "summary": "I am moving a hefty amount of data to a new ZFS pool due to some corruption and I want to avoid using for this just to make sure I don't propagate any...",
      "date_published": "2024-12-11T10:52:23Z",
      "date_modified": "2024-12-11T10:52:23Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "terminal",
        "cli",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/d-and-uninterruptable-sleep/",
      "url": "https://pype.dev/d-and-uninterruptable-sleep/",
      "title": "D and uninterruptable sleep",
      "content_html": "\u003ch2 id=\"htop\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eHtop\u003c/span\u003e \u003ca href=\"#htop\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003cp\u003eI recently have been having significant home server issues, and that\u0026rsquo;s not the point of this - today I learned what \u003ccode\u003eD\u003c/code\u003e state is when looking at htop.\u003c/p\u003e\n\u003cimg src=\"https://cdn.statically.io/gh/pypeaday/images.pype.dev/main/blog-media/d-htop.png\" alt=\"htop-d\" title=\"htop with D state\" /\u003e\n\u003cp\u003eApparently this means \u0026ldquo;uninterruptable sleep\u0026rdquo; and it\u0026rsquo;s a dev\u0026rsquo;s nightmare\u0026hellip;\u003c/p\u003e\n\u003ch3 id=\"context\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eContext\u003c/span\u003e \u003ca href=\"#context\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h3\u003e\n\u003cp\u003eThe issue I was having was that some \u003ccode\u003ezfs rollback\u003c/code\u003e commands were hung - for hours\u0026hellip; I wasn\u0026rsquo;t sure what was going on, rollbacks should be instant but I figured it was just an artifact of these issues.\u003c/p\u003e\n\u003cp\u003eTurns out I still don\u0026rsquo;t know what locked the disks up but I learned why \u003ccode\u003e\u0026lt;C\u0026gt;-c\u003c/code\u003e did \u003cstrong\u003enothing\u003c/strong\u003e\u0026hellip;\nthe more you know\u003c/p\u003e\n",
      "content_text": "\n## Htop\n\nI recently have been having significant home server issues, and that's not the point of this - today I learned what `D` state is when looking at htop.\n\n\n\u003cimg src=\"https://cdn.statically.io/gh/pypeaday/images.pype.dev/main/blog-media/d-htop.png\" alt=\"htop-d\" title=\"htop with D state\" /\u003e\n\nApparently this means \"uninterruptable sleep\" and it's a dev's nightmare... \n\n### Context\n\nThe issue I was having was that some `zfs rollback` commands were hung - for hours... I wasn't sure what was going on, rollbacks should be instant but I figured it was just an artifact of these issues.\n\nTurns out I still don't know what locked the disks up but I learned why `\u003cC\u003e-c` did __nothing__...\nthe more you know\n",
      "summary": "I recently have been having significant home server issues, and that's not the point of this - today I learned what state is when looking at htop.",
      "date_published": "2024-12-11T10:48:10Z",
      "date_modified": "2024-12-11T10:48:10Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "zfs",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/hostnamectl-to-easily-change-hostname/",
      "url": "https://pype.dev/hostnamectl-to-easily-change-hostname/",
      "title": "hostnamectl to easily change hostname",
      "content_html": "\u003cp\u003ehostnamectl is apparently a linux utility for easily changing your hostname in a variety of ways\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e❯ hostnamectl --help\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ehostnamectl \u003cspan class=\"o\"\u003e[\u003c/span\u003eOPTIONS...\u003cspan class=\"o\"\u003e]\u003c/span\u003e COMMAND ...\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eQuery or change system hostname.\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eCommands:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  status                 Show current hostname settings\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  hostname \u003cspan class=\"o\"\u003e[\u003c/span\u003eNAME\u003cspan class=\"o\"\u003e]\u003c/span\u003e        Get/set system hostname\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  icon-name \u003cspan class=\"o\"\u003e[\u003c/span\u003eNAME\u003cspan class=\"o\"\u003e]\u003c/span\u003e       Get/set icon name \u003cspan class=\"k\"\u003efor\u003c/span\u003e host\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  chassis \u003cspan class=\"o\"\u003e[\u003c/span\u003eNAME\u003cspan class=\"o\"\u003e]\u003c/span\u003e         Get/set chassis \u003cspan class=\"nb\"\u003etype\u003c/span\u003e \u003cspan class=\"k\"\u003efor\u003c/span\u003e host\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  deployment \u003cspan class=\"o\"\u003e[\u003c/span\u003eNAME\u003cspan class=\"o\"\u003e]\u003c/span\u003e      Get/set deployment environment \u003cspan class=\"k\"\u003efor\u003c/span\u003e host\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  location \u003cspan class=\"o\"\u003e[\u003c/span\u003eNAME\u003cspan class=\"o\"\u003e]\u003c/span\u003e        Get/set location \u003cspan class=\"k\"\u003efor\u003c/span\u003e host\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eOptions:\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  -h --help              Show this \u003cspan class=\"nb\"\u003ehelp\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --version           Show package version\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --no-ask-password   Do not prompt \u003cspan class=\"k\"\u003efor\u003c/span\u003e password\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  -H --host\u003cspan class=\"o\"\u003e=[\u003c/span\u003eUSER@\u003cspan class=\"o\"\u003e]\u003c/span\u003eHOST  Operate on remote host\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e  -M --machine\u003cspan class=\"o\"\u003e=\u003c/span\u003eCONTAINER Operate on \u003cspan class=\"nb\"\u003elocal\u003c/span\u003e container\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --transient         Only \u003cspan class=\"nb\"\u003eset\u003c/span\u003e transient hostname\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --static            Only \u003cspan class=\"nb\"\u003eset\u003c/span\u003e static hostname\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --pretty            Only \u003cspan class=\"nb\"\u003eset\u003c/span\u003e pretty hostname\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e     --json\u003cspan class=\"o\"\u003e=\u003c/span\u003epretty\u003cspan class=\"p\"\u003e|\u003c/span\u003eshort\u003cspan class=\"p\"\u003e|\u003c/span\u003eoff\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e                         Generate JSON output\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eSee the hostnamectl\u003cspan class=\"o\"\u003e(\u003c/span\u003e1\u003cspan class=\"o\"\u003e)\u003c/span\u003e man page \u003cspan class=\"k\"\u003efor\u003c/span\u003e details.\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eI learned there\u0026rsquo;s transient and static hostnames, so that\u0026rsquo;s cool\u0026hellip;\u003c/p\u003e\n\u003cp\u003eThe thing I needed was \u003ccode\u003ehostnamectl --static hostname babyblue-aurora\u003c/code\u003e\u003c/p\u003e\n\u003cp\u003epretty sweet tool\u003c/p\u003e\n",
      "content_text": "\nhostnamectl is apparently a linux utility for easily changing your hostname in a variety of ways\n\n```bash\n\n❯ hostnamectl --help\nhostnamectl [OPTIONS...] COMMAND ...\n\nQuery or change system hostname.\n\nCommands:\n  status                 Show current hostname settings\n  hostname [NAME]        Get/set system hostname\n  icon-name [NAME]       Get/set icon name for host\n  chassis [NAME]         Get/set chassis type for host\n  deployment [NAME]      Get/set deployment environment for host\n  location [NAME]        Get/set location for host\n\nOptions:\n  -h --help              Show this help\n     --version           Show package version\n     --no-ask-password   Do not prompt for password\n  -H --host=[USER@]HOST  Operate on remote host\n  -M --machine=CONTAINER Operate on local container\n     --transient         Only set transient hostname\n     --static            Only set static hostname\n     --pretty            Only set pretty hostname\n     --json=pretty|short|off\n                         Generate JSON output\n\nSee the hostnamectl(1) man page for details.\n```\n\nI learned there's transient and static hostnames, so that's cool...\n\nThe thing I needed was `hostnamectl --static hostname babyblue-aurora`\n\npretty sweet tool\n",
      "summary": "hostnamectl is apparently a linux utility for easily changing your hostname in a variety of ways",
      "date_published": "2024-12-06T07:25:59Z",
      "date_modified": "2024-12-06T07:25:59Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "terminal",
        "homelab",
        "cli",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/dns-broke-after-reboot-ubuntu-22-04/",
      "url": "https://pype.dev/dns-broke-after-reboot-ubuntu-22-04/",
      "title": "DNS Broke After Reboot - Ubuntu 22.04",
      "content_html": "\u003cp\u003eI rebooted by server and DNS broke randomly. I have no idea if it was from a kernel update or what but that\u0026rsquo;s the issue with Ubuntu I guess\u0026hellip;\u003c/p\u003e\n\u003cp\u003eAfter much toil and none of the other options working for me (sorry to not have those documented here) this is what got me the vic from this \u003ca href=\"https://askubuntu.com/questions/1406827/how-to-set-dns-on-ubuntu-22-04-when-you-have-no-netplan-config\"\u003eSO Post\u003c/a\u003e\u003c/p\u003e\n\u003cp\u003esudo mkdir /etc/systemd/resolved.conf.d/\nsudo $EDITOR /etc/systemd/resolved.conf.d/dns_servers.conf\u003c/p\u003e\n\u003cp\u003eMost folks probably are good with google (8.8.8.8) and cloudflare (1.1.1.1)\u003c/p\u003e\n\u003cpre\u003e\u003ccode\u003e[Resolve]\nDNS=8.8.8.8 1.1.1.1\n\u003c/code\u003e\u003c/pre\u003e\n\u003cp\u003eBut I decided to use tailscale\u003c/p\u003e\n\u003cpre\u003e\u003ccode\u003e[Resolve]\nDNS=100.100.100.100\n\u003c/code\u003e\u003c/pre\u003e\n\u003cp\u003eThen restart systemd-resolved\u003c/p\u003e\n\u003cp\u003esudo systemctl restart systemd-resolved\u003c/p\u003e\n",
      "content_text": "\nI rebooted by server and DNS broke randomly. I have no idea if it was from a kernel update or what but that's the issue with Ubuntu I guess...\n\nAfter much toil and none of the other options working for me (sorry to not have those documented here) this is what got me the vic from this [SO Post](https://askubuntu.com/questions/1406827/how-to-set-dns-on-ubuntu-22-04-when-you-have-no-netplan-config)\n\nsudo mkdir /etc/systemd/resolved.conf.d/\nsudo $EDITOR /etc/systemd/resolved.conf.d/dns_servers.conf\n\nMost folks probably are good with google (8.8.8.8) and cloudflare (1.1.1.1)\n\n```\n[Resolve]\nDNS=8.8.8.8 1.1.1.1\n```\n\nBut I decided to use tailscale\n\n```\n[Resolve]\nDNS=100.100.100.100\n```\n\nThen restart systemd-resolved\n\nsudo systemctl restart systemd-resolved\n",
      "summary": "I rebooted by server and DNS broke randomly. I have no idea if it was from a kernel update or what but that's the issue with Ubuntu I guess...",
      "date_published": "2024-11-22T08:08:40Z",
      "date_modified": "2024-11-22T08:08:40Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/restart-kde-plasma/",
      "url": "https://pype.dev/restart-kde-plasma/",
      "title": "Restart KDE Plasma",
      "content_html": "\u003cp\u003ePlasma shits the bed a little too often on Fedora for me right now but I finally have a quick fix\u0026hellip;\u003c/p\u003e\n\u003cpre\u003e\u003ccode\u003e\nsudo killall plasmashell\n\nkstart plasmashell\n\n\u003c/code\u003e\u003c/pre\u003e\n",
      "content_text": "\nPlasma shits the bed a little too often on Fedora for me right now but I finally have a quick fix...\n\n```\n\nsudo killall plasmashell\n\nkstart plasmashell\n\n```\n",
      "summary": "Plasma shits the bed a little too often on Fedora for me right now but I finally have a quick fix...",
      "date_published": "2024-11-08T15:53:52Z",
      "date_modified": "2024-11-08T15:53:52Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "terminal",
        "cli",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/docker-remote-add/",
      "url": "https://pype.dev/docker-remote-add/",
      "title": "docker-remote-add",
      "content_html": "\u003cp\u003eAdd from url??\u003c/p\u003e\n\u003cp\u003eADD \u003ca href=\"http://example.com/cars.csv\"\u003ehttp://example.com/cars.csv\u003c/a\u003e /tmp/cars.csv\u003c/p\u003e\n\u003cp\u003eUnpack automatically!? (.tar, .tar.gz, .tgz, .bz2, .tbz2, .txz, .zip)\u003c/p\u003e\n\u003cp\u003eADD myapp.tar.gz /opt/myapp/\u003c/p\u003e\n",
      "content_text": "\nAdd from url??\n\nADD http://example.com/cars.csv /tmp/cars.csv\n\nUnpack automatically!? (.tar, .tar.gz, .tgz, .bz2, .tbz2, .txz, .zip)\n\nADD myapp.tar.gz /opt/myapp/\n",
      "summary": "Add from url??",
      "date_published": "2024-09-17T06:19:00Z",
      "date_modified": "2024-09-17T06:19:00Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/docker-copy-and-chown/",
      "url": "https://pype.dev/docker-copy-and-chown/",
      "title": "Docker copy and chown",
      "content_html": "\u003cp\u003eCOPY \u0026ndash;chown=myuser:mygroup source-file target-file\u003c/p\u003e\n",
      "content_text": "\nCOPY --chown=myuser:mygroup source-file target-file\n",
      "summary": "COPY --chown=myuser:mygroup source-file target-file",
      "date_published": "2024-09-17T06:18:09Z",
      "date_modified": "2024-09-17T06:18:09Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "homelab",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/interesting-ips-between-jellyfin-clients-and-server-depending-on-tailscale-and-server-address/",
      "url": "https://pype.dev/interesting-ips-between-jellyfin-clients-and-server-depending-on-tailscale-and-server-address/",
      "title": "Interesting IPs between Jellyfin clients and server depending on tailscale and server address",
      "content_html": "\u003cp\u003eWhen connecting from my phone to jellyfin I\u0026rsquo;m seeing some interesting patterns.\u003c/p\u003e\n\u003ch2 id=\"scenarios\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eScenarios\u003c/span\u003e \u003ca href=\"#scenarios\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h2\u003e\n\u003ch3 id=\"tailscale-ip-of-phone-is-listed-as-local-network-to-jellyfin\"\u003e\u003cspan class=\"heading-wear-glyph\"\u003eTailscale IP of phone is listed as local network to jellyfin\u003c/span\u003e \u003ca href=\"#tailscale-ip-of-phone-is-listed-as-local-network-to-jellyfin\" class=\"heading-anchor\"\u003e#\u003c/a\u003e\u003c/h3\u003e\n\u003cp\u003eWifi: off\nTailscale: on\nUse exit node: on\nLAN access: on\nJellyfin: LAN IP\u003c/p\u003e\n\u003cp\u003eJellyfin sees 192.168.1.1, my router address\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: off\ntailscale: on\nUse exit node: on\nLAN access: on\nJellyfin: Tailscale magic DNS\u003c/p\u003e\n\u003cp\u003eJellyfin sees the \u003ca href=\"/docker/\" class=\"glossary-term\" title=\"docker - container runtime\" data-hover-title=\"docker\"\u003edocker\u003c/a\u003e bridge network\u003c/p\u003e\n\u003cp\u003eQ: This might be because of traefik somehow\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: off\ntailsacale: on\nUse exit node: on\nLAN access: off\nJellyfin: LAN IP\u003c/p\u003e\n\u003cp\u003eJellyfin sees the 192.168.1.1\u003c/p\u003e\n\u003cp\u003eQ: Why did this work even work?\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: off\ntailsacale: on\nUse exit node: on\nLAN access: off\nJellyfin: Tailscale magic DNS\u003c/p\u003e\n\u003cp\u003eJellyfin sees the docker bridge network\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: off\ntailsacale: on\nUse exit node: off\nLAN access: off\nJellyfin: LAN IP\u003c/p\u003e\n\u003cp\u003eJellyfin sees the 192.168.1.1\u003c/p\u003e\n\u003cp\u003eQ: Why did this work?\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: off\ntailsacale: on\nUse exit node: off\nLAN access: off\nJellyfin: Tailscale magic DNS\u003c/p\u003e\n\u003cp\u003eJellyfin sees the docker bridge network\u003c/p\u003e\n\u003chr\u003e\n\u003cp\u003eWifi: on\ntailsacale: of\nUse exit node: off\nLAN access: off\nJellyfin: LAN IP (via pihole DNS)\u003c/p\u003e\n\u003cp\u003eJellyfin sees the IP of my phone\u003c/p\u003e\n\u003chr\u003e\n",
      "content_text": "\nWhen connecting from my phone to jellyfin I'm seeing some interesting patterns.\n\n## Scenarios\n\n### Tailscale IP of phone is listed as local network to jellyfin\n\nWifi: off\nTailscale: on\nUse exit node: on\nLAN access: on\nJellyfin: LAN IP\n\nJellyfin sees 192.168.1.1, my router address\n\n***\n\nWifi: off\ntailscale: on\nUse exit node: on \nLAN access: on\nJellyfin: Tailscale magic DNS\n\nJellyfin sees the docker bridge network\n\nQ: This might be because of traefik somehow\n\n***\n\nWifi: off\ntailsacale: on\nUse exit node: on\nLAN access: off\nJellyfin: LAN IP\n\nJellyfin sees the 192.168.1.1\n\nQ: Why did this work even work?\n\n***\n\nWifi: off\ntailsacale: on\nUse exit node: on\nLAN access: off\nJellyfin: Tailscale magic DNS\n\nJellyfin sees the docker bridge network\n\n***\n\nWifi: off\ntailsacale: on\nUse exit node: off\nLAN access: off\nJellyfin: LAN IP\n\nJellyfin sees the 192.168.1.1\n\nQ: Why did this work?\n\n***\n\nWifi: off\ntailsacale: on\nUse exit node: off\nLAN access: off\nJellyfin: Tailscale magic DNS\n\nJellyfin sees the docker bridge network\n\n***\n\nWifi: on\ntailsacale: of\nUse exit node: off\nLAN access: off\nJellyfin: LAN IP (via pihole DNS)\n\nJellyfin sees the IP of my phone\n\n***\n",
      "summary": "When connecting from my phone to jellyfin I'm seeing some interesting patterns.",
      "date_published": "2024-07-12T06:24:57Z",
      "date_modified": "2024-07-12T06:24:57Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech"
      ]
    },
    {
      "id": "https://pype.dev/upgrading-your-kernel-can-f-you-up-whoops/",
      "url": "https://pype.dev/upgrading-your-kernel-can-f-you-up-whoops/",
      "title": "Upgrading your kernel can F you up… whoops",
      "content_html": "\u003cp\u003e\u003ca href=\"https://forum.proxmox.com/threads/update-error-with-coral-tpu-drivers.136888/#post-608975\"\u003ehttps://forum.proxmox.com/threads/update-error-with-coral-tpu-drivers.136888/#post-608975\u003c/a\u003e I lost TPU for frigate, this saved me ass\u003c/p\u003e\n",
      "content_text": "\nhttps://forum.proxmox.com/threads/update-error-with-coral-tpu-drivers.136888/#post-608975 I lost TPU for frigate, this saved me ass\n",
      "summary": "https://forum.proxmox.com/threads/update-error-with-coral-tpu-drivers.136888/#post-608975 I lost TPU for frigate, this saved me ass",
      "date_published": "2024-06-26T10:21:59Z",
      "date_modified": "2024-06-26T10:21:59Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/dhcp-restart-to-save-ubuntu-22-04-server-networking/",
      "url": "https://pype.dev/dhcp-restart-to-save-ubuntu-22-04-server-networking/",
      "title": "DHCP Restart to Save Ubuntu 22.04 Server Networking",
      "content_html": "\u003cp\u003eI moved a computer to a remote location for an off-site backup but when it was powered on it wouldn\u0026rsquo;t show up on any networks. A solution that got me back in was a friend restarting the dhcp client for me:\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003esudo dhclient -r -v \u0026lt;interface\u0026gt; \u003cspan class=\"o\"\u003e\u0026amp;\u0026amp;\u003c/span\u003e sudo dhclient -v \u0026lt;interface\u0026gt;\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e",
      "content_text": "\nI moved a computer to a remote location for an off-site backup but when it was powered on it wouldn't show up on any networks. A solution that got me back in was a friend restarting the dhcp client for me:\n\n```bash\nsudo dhclient -r -v \u003cinterface\u003e \u0026\u0026 sudo dhclient -v \u003cinterface\u003e\n```\n",
      "summary": "I moved a computer to a remote location for an off-site backup but when it was powered on it wouldn't show up on any networks. A solution that got me back in...",
      "date_published": "2023-12-31T20:26:50Z",
      "date_modified": "2023-12-31T20:26:50Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/refresh-nextcloud-groupfolders-after-messing-around-on-the-filesystem/",
      "url": "https://pype.dev/refresh-nextcloud-groupfolders-after-messing-around-on-the-filesystem/",
      "title": "Refresh Nextcloud Groupfolders after messing around on the filesystem",
      "content_html": "\u003cp\u003eExec in as www-data and run ./occ groupfolders:scan folder_id -v (the -v to see what it\u0026rsquo;s doing)\u003c/p\u003e\n",
      "content_text": "\nExec in as www-data and run ./occ groupfolders:scan folder_id -v (the -v to see what it's doing)\n",
      "summary": "Exec in as www-data and run ./occ groupfolders:scan folder_id -v (the -v to see what it's doing)",
      "date_published": "2023-09-23T12:45:06Z",
      "date_modified": "2023-09-23T12:45:06Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "homelab",
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/convert-word-doc-to-pdf-with-headless-libreoffice/",
      "url": "https://pype.dev/convert-word-doc-to-pdf-with-headless-libreoffice/",
      "title": "Convert Word Doc to PDF with Headless Libreoffice",
      "content_html": "\u003cp\u003eI\u0026rsquo;ve been using paperless-ngx to manage all my documents, but every once in a while I\u0026rsquo;ll get a \u003ccode\u003e.docx\u003c/code\u003e file to deal with\u0026hellip;\u003c/p\u003e\n\u003cp\u003eTurns out Libreoffice has a headless mode a \u003ccode\u003epdf\u003c/code\u003e converter built-in!\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003elibreoffice --headless --convert-to pdf /path/to/file.docx --outdir /path/to/output/directory\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cblockquote\u003e\n\u003cp\u003eNote that \u003ccode\u003e--outdir\u003c/code\u003e is in fact a directory, not the path to a file\u003c/p\u003e\n\u003c/blockquote\u003e\n",
      "content_text": "\nI've been using paperless-ngx to manage all my documents, but every once in a while I'll get a `.docx` file to deal with...\n\nTurns out Libreoffice has a headless mode a `pdf` converter built-in!\n\n```Bash\nlibreoffice --headless --convert-to pdf /path/to/file.docx --outdir /path/to/output/directory\n```\n\n\u003e Note that `--outdir` is in fact a directory, not the path to a file\n",
      "summary": "I've been using paperless-ngx to manage all my documents, but every once in a while I'll get a file to deal with...",
      "date_published": "2023-03-09T06:48:38Z",
      "date_modified": "2023-03-09T06:48:38Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "cli",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/i3-like-keyboard-mapping-in-pop-os/",
      "url": "https://pype.dev/i3-like-keyboard-mapping-in-pop-os/",
      "title": "i3-Like keyboard mapping in Pop_OS",
      "content_html": "\u003cp\u003eI was introduced to tiling window managers through i3, which I use heavily on\none of my machines. I have switched to Pop_OS! at home though, which has a\ntiling window mode but the keybindings are not what I\u0026rsquo;m used to for i3. I\nwanted to at least navigate workspaces how I\u0026rsquo;m used to doing (cause I set\nworkspace 3 for communication apps, 1 for my terminal, etc\u0026hellip;)\u003c/p\u003e\n\u003cp\u003eHere\u0026rsquo;s how I set keybindings for:\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003ccode\u003e\u0026lt;Super\u0026gt; + \u0026lt;number\u0026gt;\u003c/code\u003e sends me to that numbered workspace\u003c/li\u003e\n\u003cli\u003e\u003ccode\u003e\u0026lt;Shift\u0026gt; + \u0026lt;Super\u0026gt; + \u0026lt;number\u0026gt;\u003c/code\u003e moves the window I\u0026rsquo;m focused on to workspace \u003ccode\u003enumber\u003c/code\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"cp\"\u003e#!/bin/bash\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.mutter dynamic-workspaces \u003cspan class=\"nb\"\u003efalse\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.preferences num-workspaces \u003cspan class=\"m\"\u003e8\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-1 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-2 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-3 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-4 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-5 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-6 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-7 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-8 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.shell.keybindings switch-to-application-9 \u003cspan class=\"o\"\u003e[]\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-1 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;1\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-2 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;2\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-3 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;3\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-4 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;4\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-5 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;5\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-6 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;6\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-7 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;7\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-8 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;8\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-9 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;9\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings switch-to-workspace-10 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;0\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-1 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;1\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-2 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;2\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-3 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;3\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-4 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;4\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-5 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;5\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-6 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;6\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-7 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;7\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-8 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;8\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-9 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;9\u0026#39;]\u0026#34;\u003c/span\u003e \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egsettings \u003cspan class=\"nb\"\u003eset\u003c/span\u003e org.gnome.desktop.wm.keybindings move-to-workspace-10 \u003cspan class=\"s2\"\u003e\u0026#34;[\u0026#39;\u0026lt;Super\u0026gt;\u0026lt;Shift\u0026gt;0\u0026#39;]\u0026#34;\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e",
      "content_text": "\nI was introduced to tiling window managers through i3, which I use heavily on\none of my machines. I have switched to Pop_OS! at home though, which has a\ntiling window mode but the keybindings are not what I'm used to for i3. I\nwanted to at least navigate workspaces how I'm used to doing (cause I set\nworkspace 3 for communication apps, 1 for my terminal, etc...)\n\nHere's how I set keybindings for:\n\n* `\u003cSuper\u003e + \u003cnumber\u003e` sends me to that numbered workspace\n* `\u003cShift\u003e + \u003cSuper\u003e + \u003cnumber\u003e` moves the window I'm focused on to workspace `number`\n\n```bash\n#!/bin/bash\ngsettings set org.gnome.mutter dynamic-workspaces false \ngsettings set org.gnome.desktop.wm.preferences num-workspaces 8 \ngsettings set org.gnome.shell.keybindings switch-to-application-1 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-2 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-3 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-4 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-5 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-6 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-7 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-8 [] \ngsettings set org.gnome.shell.keybindings switch-to-application-9 [] \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-1 \"['\u003cSuper\u003e1']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-2 \"['\u003cSuper\u003e2']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-3 \"['\u003cSuper\u003e3']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-4 \"['\u003cSuper\u003e4']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-5 \"['\u003cSuper\u003e5']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-6 \"['\u003cSuper\u003e6']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-7 \"['\u003cSuper\u003e7']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-8 \"['\u003cSuper\u003e8']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-9 \"['\u003cSuper\u003e9']\" \ngsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-10 \"['\u003cSuper\u003e0']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-1 \"['\u003cSuper\u003e\u003cShift\u003e1']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-2 \"['\u003cSuper\u003e\u003cShift\u003e2']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-3 \"['\u003cSuper\u003e\u003cShift\u003e3']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-4 \"['\u003cSuper\u003e\u003cShift\u003e4']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-5 \"['\u003cSuper\u003e\u003cShift\u003e5']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-6 \"['\u003cSuper\u003e\u003cShift\u003e6']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-7 \"['\u003cSuper\u003e\u003cShift\u003e7']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-8 \"['\u003cSuper\u003e\u003cShift\u003e8']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-9 \"['\u003cSuper\u003e\u003cShift\u003e9']\" \ngsettings set org.gnome.desktop.wm.keybindings move-to-workspace-10 \"['\u003cSuper\u003e\u003cShift\u003e0']\"\n```\n",
      "summary": "I was introduced to tiling window managers through i3, which I use heavily on one of my machines. I have switched to Pop_OS! at home though, which has a...",
      "date_published": "2023-01-12T05:51:25Z",
      "date_modified": "2023-01-12T05:51:25Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "tech",
        "til"
      ]
    },
    {
      "id": "https://pype.dev/use-non-standard-named-ssh-keys-with-github/",
      "url": "https://pype.dev/use-non-standard-named-ssh-keys-with-github/",
      "title": "Use non-standard named ssh keys with github",
      "content_html": "\u003cp\u003eI was getting \u003ccode\u003e(publickey denied)\u003c/code\u003e when trying to push to GH using ssh. When I\ntested the connection I saw that a bunch of keys in ``~/.ssh/ were being\nattempted\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003e✗ ssh git@github.com -vv\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"err\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003e...\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"err\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_rsa \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_ecdsa \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_ecdsa_sk \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_ed25519 \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_ed25519_sk \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_xmss \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: Will attempt key: /home/nic/.ssh/id_dsa \n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"err\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003e...\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"err\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003edebug1: No more authentication methods to try.\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"go\"\u003egit@github.com: Permission denied (publickey).\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\u003cspan class=\"err\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eNone of those were the key I setup with GH. So I added an entry\ninto \u003ccode\u003e~/.ssh/config\u003c/code\u003e:\u003c/p\u003e\n\u003cpre class=\"chroma\"\u003e\u003ccode\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eHost\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003egithub.com\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eUser git\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003ePort 22\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eHostname github.com\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eIdentityFile ~/.ssh/my_custom_github_key\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eTCPKeepAlive yes\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003eIdentitiesOnly yes \n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"cl\"\u003e\n\u003c/span\u003e\u003c/span\u003e\u003c/code\u003e\u003c/pre\u003e",
      "content_text": "\nI was getting `(publickey denied)` when trying to push to GH using ssh. When I\ntested the connection I saw that a bunch of keys in ``~/.ssh/ were being\nattempted\n\n```console\n✗ ssh git@github.com -vv\n\n...\n\ndebug1: Will attempt key: /home/nic/.ssh/id_rsa \ndebug1: Will attempt key: /home/nic/.ssh/id_ecdsa \ndebug1: Will attempt key: /home/nic/.ssh/id_ecdsa_sk \ndebug1: Will attempt key: /home/nic/.ssh/id_ed25519 \ndebug1: Will attempt key: /home/nic/.ssh/id_ed25519_sk \ndebug1: Will attempt key: /home/nic/.ssh/id_xmss \ndebug1: Will attempt key: /home/nic/.ssh/id_dsa \n\n...\n\ndebug1: No more authentication methods to try.\ngit@github.com: Permission denied (publickey).\n\n```\n\nNone of those were the key I setup with GH. So I added an entry\ninto `~/.ssh/config`:\n\n```text\nHost\ngithub.com\nUser git\nPort 22\nHostname github.com\nIdentityFile ~/.ssh/my_custom_github_key\nTCPKeepAlive yes\nIdentitiesOnly yes \n\n```\n\n",
      "summary": "I was getting when trying to push to GH using ssh. When I tested the connection I saw that a bunch of keys in ``~/.ssh/ were being attempted",
      "date_published": "2023-01-03T08:34:50Z",
      "date_modified": "2023-01-03T08:34:50Z",
      "authors": [
        {
          "name": "Nic Payne",
          "url": "https://pype.dev"
        }
      ],
      "tags": [
        "linux",
        "cli",
        "tech",
        "til"
      ]
    }
  ]
}