<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Arch Linux Post-Install Automation on Spoljarevic's Knowledgebase</title><link>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/</link><description>Recent content in Arch Linux Post-Install Automation on Spoljarevic's Knowledgebase</description><generator>Hugo</generator><language>en-US</language><lastBuildDate>Sun, 05 Jul 2026 18:47:44 +0200</lastBuildDate><atom:link href="https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/index.xml" rel="self" type="application/rss+xml"/><item><title>Introduction</title><link>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Introduction/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Introduction/</guid><description>&lt;p&gt;&lt;strong&gt;Arch Linux Post-Install Automation&lt;/strong&gt; is an &lt;a href="https://www.ansible.com/"&gt;Ansible&lt;/a&gt; playbook that takes a fresh&#10;Arch Linux (or Arch-based, e.g. &lt;a href="https://cachyos.org/"&gt;CachyOS&lt;/a&gt;) install and turns it into a fully configured&#10;daily-driver machine — without manually installing packages, enabling services, or configuring your shell one&#10;by one.&lt;/p&gt;&#10;&lt;h2 id="what-it-does"&gt;What it does&#10;&lt;/h2&gt;&#10;&lt;p&gt;Run against a target host, the playbook will:&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;Bootstrap the &lt;strong&gt;CachyOS&lt;/strong&gt; and &lt;strong&gt;BlackArch&lt;/strong&gt; pacman repositories&lt;/li&gt;&#10;&lt;li&gt;Install a full package set via &lt;code&gt;pacman&lt;/code&gt;, the AUR (via &lt;code&gt;yay&lt;/code&gt;), Flatpak, and Snap&lt;/li&gt;&#10;&lt;li&gt;Apply basic &lt;strong&gt;system hardening&lt;/strong&gt; (firewalld, fail2ban, &lt;code&gt;doas&lt;/code&gt;, a non-default SSH port, disabled password&#10;authentication)&lt;/li&gt;&#10;&lt;li&gt;Create a standard set of user directories (&lt;code&gt;Documents&lt;/code&gt;, &lt;code&gt;Downloads&lt;/code&gt;, &lt;code&gt;Pictures/wallpaper&lt;/code&gt;, &lt;code&gt;git&lt;/code&gt;, &amp;hellip;)&lt;/li&gt;&#10;&lt;li&gt;Install and configure &lt;strong&gt;Zsh&lt;/strong&gt; with Oh My Zsh, Powerlevel10k, and a Nerd Font&lt;/li&gt;&#10;&lt;li&gt;Generate SSH and GPG keys and configure &lt;code&gt;git&lt;/code&gt; for signed commits&lt;/li&gt;&#10;&lt;li&gt;Clone a set of personal repositories (dotfiles, wallpapers, other projects)&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="why-it-exists"&gt;Why it exists&#10;&lt;/h2&gt;&#10;&lt;p&gt;Re-installing Arch (or setting up a new machine) used to mean an hour or more of repetitive manual setup.&#10;This playbook exists so that process is a single command: point Ansible at a host, get a coffee, and come&#10;back to a fully configured system.&lt;/p&gt;</description></item><item><title>Usage</title><link>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Usage/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Usage/</guid><description>&lt;h2 id="prerequisites"&gt;Prerequisites&#10;&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;A control machine with &lt;a href="https://docs.ansible.com/"&gt;Ansible&lt;/a&gt; installed.&lt;/li&gt;&#10;&lt;li&gt;A target host running Arch Linux (or an Arch-based distro such as CachyOS), reachable over SSH with a user&#10;that can &lt;code&gt;become&lt;/code&gt; root (sudo).&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;div class="td-callout td-callout--warning" role="note"&gt;&#10; &lt;div class="td-callout__title"&gt;&lt;i class="td-callout__icon fa-solid fa-triangle-exclamation" aria-hidden="true"&gt;&lt;/i&gt;&lt;span class="td-callout__label"&gt;Warning&lt;/span&gt;&lt;/div&gt;&#10; &lt;div class="td-callout__body"&gt;&#10;&lt;p&gt;This playbook is built for Arch Linux specifically — it uses &lt;code&gt;pacman&lt;/code&gt;, and adds CachyOS/BlackArch&#10;repositories. Running it against a different distribution will fail.&lt;/p&gt;&#10; &lt;/div&gt;&#10;&lt;/div&gt;&lt;h2 id="1-install-required-ansible-collections"&gt;1. Install required Ansible collections&#10;&lt;/h2&gt;&#10;&lt;p&gt;The playbook depends on a few community Ansible collections:&lt;/p&gt;</description></item><item><title>Code Explanation</title><link>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Code-Explanation/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Code-Explanation/</guid><description>&lt;h2 id="repository-layout"&gt;Repository layout&#10;&lt;/h2&gt;&#10;&lt;div class="td-code td-code--untitled" id="td-code-f3e344f0-fence-0" data-td-code data-td-code-auto-id&#10; data-td-language="" data-td-line-count="5"&gt;&#10; &lt;div class="td-code__viewport" id="td-code-f3e344f0-fence-0-viewport" data-td-code-viewport&gt;&lt;pre tabindex="0"&gt;&lt;code&gt;archPostInstall.yml the full playbook — every play, in order&#10;spo-pc-ls.yml ansible-vault encrypted secrets (not usable by others as-is)&#10;inventory.ini example Ansible inventory&#10;requirenments.yml Ansible Galaxy collection dependencies&#10;snippets/ the same plays, split into standalone, individually runnable playbooks&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#10;&lt;/div&gt;&#10;&lt;div class="td-callout td-callout--note" role="note"&gt;&#10; &lt;div class="td-callout__title"&gt;&lt;i class="td-callout__icon fa-solid fa-circle-info" aria-hidden="true"&gt;&lt;/i&gt;&lt;span class="td-callout__label"&gt;Note&lt;/span&gt;&lt;/div&gt;&#10; &lt;div class="td-callout__body"&gt;&#10;&lt;p&gt;The dependencies file is named &lt;code&gt;requirenments.yml&lt;/code&gt; (not &lt;code&gt;requirements.yml&lt;/code&gt;) — use that exact filename&#10;when installing collections.&lt;/p&gt;&#10; &lt;/div&gt;&#10;&lt;/div&gt;&lt;h2 id="archpostinstallyml"&gt;&lt;code&gt;archPostInstall.yml&lt;/code&gt;&#10;&lt;/h2&gt;&#10;&lt;p&gt;This is the &amp;ldquo;run everything&amp;rdquo; entrypoint. It&amp;rsquo;s a sequence of independent Ansible plays, executed top to&#10;bottom:&lt;/p&gt;</description></item><item><title>FAQ</title><link>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/FAQ/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/FAQ/</guid><description>&lt;h3 id="can-i-run-this-on-a-different-distro"&gt;Can I run this on a different distro?&#10;&lt;/h3&gt;&#10;&lt;p&gt;No. It relies on &lt;code&gt;pacman&lt;/code&gt;, and specifically bootstraps the CachyOS and BlackArch pacman repositories. It&#10;will not work on Debian/Fedora/etc.&lt;/p&gt;&#10;&lt;h3 id="do-i-have-to-run-the-entire-playbook"&gt;Do I have to run the entire playbook?&#10;&lt;/h3&gt;&#10;&lt;p&gt;No — run only what you need via the standalone playbooks in &lt;code&gt;snippets/&lt;/code&gt;. See&#10;&lt;a href="https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Code-Explanation/#snippets"&gt;Code Explanation&lt;/a&gt; for the full list, and &lt;a href="https://kb-migration.spoljarevic.sh/Big-Projects/Arch-Linux-Post-Install-Automation/Usage/"&gt;Usage&lt;/a&gt; for an example&#10;command.&lt;/p&gt;</description></item></channel></rss>