<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>EdFig.dev</title>
    <link>https://edfig.dev/eddie/</link>
    <description>Musings, DIY projects, Linux, IaC, and other things.</description>
    <pubDate>Sun, 06 Sep 2026 03:24:17 +0000</pubDate>
    <item>
      <title>Actually Writing Things Down</title>
      <link>https://edfig.dev/eddie/actually-writing-things-down</link>
      <description>&lt;![CDATA[I&#39;ve been at jury duty for weeks on a long running court case. in that time we&#39;re only allowed to take hand written notes on small legal pads that we can&#39;t take with us. &#xA;&#xA;I&#39;ve actually been enjoying the process and figuring out a good writing and reference system for myself. &#xA;&#xA;I&#39;ll try to update this post with some examples later but I&#39;m putting it up now so I can finish out Blaugust on a win.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<p>I&#39;ve been at jury duty for weeks on a long running court case. in that time we&#39;re only allowed to take hand written notes on small legal pads that we can&#39;t take with us.</p>

<p>I&#39;ve actually been enjoying the process and figuring out a good writing and reference system for myself.</p>

<p>I&#39;ll try to update this post with some examples later but I&#39;m putting it up now so I can finish out <a href="https://nerdgirlthoughts.game.blog/2026/07/15/blaugust-2026-is-coming/" rel="nofollow">Blaugust</a> on a win.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/actually-writing-things-down</guid>
      <pubDate>Thu, 27 Aug 2026 01:35:20 +0000</pubDate>
    </item>
    <item>
      <title>Index out of range in terrafrom</title>
      <link>https://edfig.dev/eddie/index-out-of-range-in-terrafrom</link>
      <description>&lt;![CDATA[Accidently nuked half of some resources and broke DNS (yes, it is in fact always DNS). One of the first things I learned and is on a lot of guides for terraform is how count works. It’s one of the meta-arguments you can use with most resources, others are&#xA;&#xA;dependson&#xA;count&#xA;foreach&#xA;provider / providers&#xA;lifecycle&#xA;&#xA;Here’s an example for count before I show my oops.&#xA;&#xA;variable &#34;names&#34; {&#xA;  default = [&#34;alice&#34;, &#34;bob&#34;, &#34;carol&#34;]&#xA;}&#xA;&#xA;resource &#34;awsinstance&#34; &#34;web&#34; {&#xA;  count         = length(var.names)&#xA;  ami           = &#34;ami-0c55b159cbfafe1f0&#34;&#xA;  instancetype = &#34;t3.micro&#34;&#xA;&#xA;  tags = {&#xA;    Name = var.names[count.index]&#xA;  }&#xA;}&#xA;&#xA;Remove &#34;bob&#34; → default = [&#34;alice&#34;, &#34;carol&#34;]. You’ll see this in your terraform run of web[1] transitioning.&#xA;&#xA;  ~ Name = &#34;bob&#34; -  &#34;carol&#34;&#xA;&#xA;carol shifts from index 2 → 1, so Terraform modifies the bob instance to become carol, and destroys the old carol. Two changes instead of one.&#xA;&#xA;count is very quick and easy to use but honestly I avoided it. If I read of a feature that has to be used with extra considerations, I’d rather use the pattern that doesn’t let me screw up if my coffee has fully kicked in.&#xA;&#xA;---&#xA;&#xA;In my case, I added to middle of an array in a variable but the implementation logic was a count instead of a foreach.&#xA;&#xA;Here’s an implementation that guarentess uniqness in the array to avoid collisions and doesn’t care about order.&#xA;&#xA;Before (vulnerable — index shuffle on any list change)&#xA;resource &#34;awsinstance&#34; &#34;web&#34; {&#xA;  count         = length(var.names)&#xA;  ami           = &#34;ami-0c55b159cbfafe1f0&#34;&#xA;  instancetype = &#34;t3.micro&#34;&#xA;&#xA;  tags = {&#xA;    Name = var.names[count.index]&#xA;  }&#xA;}&#xA;&#xA;After (safe — each instance is an independent resource)&#xA;resource &#34;awsinstance&#34; &#34;web&#34; {&#xA;  foreach      = toset(var.instances)&#xA;  ami           = &#34;ami-0c55b159cbfafe1f0&#34;&#xA;  instancetype = &#34;t3.micro&#34;&#xA;&#xA;  tags = {&#xA;    Name = each.key&#xA;  }&#xA;}&#xA;&#xA;Even better is that with the first method you access the resource like awsinstance.web[0] but with the 2nd you get a much more descriptive and assuring awsinstance.web[&#34;bob&#34;]&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<p>Accidently nuked half of some resources and broke DNS (yes, it is in fact always DNS). One of the first things I learned and is on a lot of guides for terraform is how <code>count</code> works. It’s one of the meta-arguments you can use with most resources, others are</p>

<pre><code>depends_on
count
for_each
provider / providers
lifecycle
</code></pre>

<p>Here’s an example for count before I show my oops.</p>

<pre><code class="language-hcl">variable &#34;names&#34; {
  default = [&#34;alice&#34;, &#34;bob&#34;, &#34;carol&#34;]
}

resource &#34;aws_instance&#34; &#34;web&#34; {
  count         = length(var.names)
  ami           = &#34;ami-0c55b159cbfafe1f0&#34;
  instance_type = &#34;t3.micro&#34;

  tags = {
    Name = var.names[count.index]
  }
}
</code></pre>

<p>Remove <code>&#34;bob&#34;</code> → <code>default = [&#34;alice&#34;, &#34;carol&#34;]</code>. You’ll see this in your terraform run of web[1] transitioning.</p>

<pre><code>  ~ Name = &#34;bob&#34; -&gt; &#34;carol&#34;
</code></pre>

<p>carol shifts from index 2 → 1, so Terraform modifies the bob instance to become carol, and destroys the old carol. Two changes instead of one.</p>

<p><code>count</code> is very quick and easy to use but honestly I avoided it. If I read of a feature that has to be used with extra considerations, I’d rather use the pattern that doesn’t let me screw up if my coffee has fully kicked in.</p>

<hr>

<p>In my case, I added to middle of an array in a variable but the implementation logic was a count instead of a <code>for_each</code>.</p>

<p>Here’s an implementation that guarentess uniqness in the array to avoid collisions and doesn’t care about order.</p>

<pre><code class="language-hcl"># Before (vulnerable — index shuffle on any list change)
resource &#34;aws_instance&#34; &#34;web&#34; {
  count         = length(var.names)
  ami           = &#34;ami-0c55b159cbfafe1f0&#34;
  instance_type = &#34;t3.micro&#34;

  tags = {
    Name = var.names[count.index]
  }
}

# After (safe — each instance is an independent resource)
resource &#34;aws_instance&#34; &#34;web&#34; {
  for_each      = toset(var.instances)
  ami           = &#34;ami-0c55b159cbfafe1f0&#34;
  instance_type = &#34;t3.micro&#34;

  tags = {
    Name = each.key
  }
}
</code></pre>

<p>Even better is that with the first method you access the resource like <code>aws_instance.web[0]</code> but with the 2nd you get a much more descriptive and assuring <code>aws_instance.web[&#34;bob&#34;]</code></p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/index-out-of-range-in-terrafrom</guid>
      <pubDate>Thu, 26 Mar 2026 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>DND One Shot Recommendations</title>
      <link>https://edfig.dev/eddie/dnd-one-shot-recommendations</link>
      <description>&lt;![CDATA[Some Recs and Resources. It’s come up a few times so I made a page to quickly share with others.&#xA;&#xA;---&#xA;&#xA;Death House&#xA;&#xA;Horror themed, prequel to Curse of Strahd, Death House is meant for 3rd to 5th level players. I’ve never ran this. Only tip I know is to not let anyone 1v1 the broom lol.&#xA;&#xA;Review&#xA;TBD :(&#xA;&#xA;---&#xA;&#xA;Study in Marble&#xA;&#xA;From the DMSguild.com page for it. Also was announced via reddit and they have some tips and suggestions.&#xA;&#xA;The richest man on the isle of Syklos has suddenly gone missing. He’s been known to have some extramarital excursions in the past, but this time is different—he hasn’t come back. Why did he disappear? Who is responsible? And what does the eccentric local sculptor have to do with it?&#xA;A Study in Marble is an adventure for a 3rd to 5th level party inspired by ancient Greek mythology. Players will unravel a mystery in an urban environment, with significant emphasis on social interaction and gathering clues; the module can be played as a one-shot or integrated into an existing campaign as a side quest. The adventure is especially suitable for campaigns set in the world of Theros, but can fit into any campaign with room for a Greek city.&#xA;&#xA;This module includes:&#xA;3 maps, in both PDF and JPG format&#xA;4 possible endings, depending on the choices made by the party&#xA;1 central plot twist that will keep your players guessing&#xA;&#xA;Review:&#xA;&#xA;Roleplay heavy, fun to run.&#xA;&#xA;---&#xA;&#xA;A Wild Sheep Chase&#xA;&#xA;A Single-Session Adventure for parties of 4th-5th level&#xA;The very first adventure produced by Winghorn Press, freshly updated with player feedback and suggestions,&#xA;as well as a brand new map. When the party’s attempt to grab a rare afternoon of downtime is interrupted by a frantic sheep equipped with a&#xA;Scroll of Speak to Animals, they’re dragged into a magical grudge match that will test their strength, courage and willingness to endure baa’d puns.&#xA;&#xA;Will our heroes be able to overcome a band of transmuted assassins and an extremely bitter apprentice packing dangerously unstable magic items? There’s only one way to find out.&#xA;&#xA;Free download here from their site&#xA;&#xA;Review:&#xA;&#xA;Can either be roleplay or combat driven. Good for new players or new DMs. I’ve got some mini’s for this one if you’d like to use them.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<p>Some Recs and Resources. It’s come up a few times so I made a page to quickly share with others.</p>

<hr>

<h2 id="death-house">Death House</h2>

<p>Horror themed, prequel to Curse of Strahd, <a href="https://media.wizards.com/2016/downloads/DND/Curse%20of%20Strahd%20Introductory%20Adventure.pdf" rel="nofollow">Death House</a> is meant for 3rd to 5th level players. I’ve never ran this. Only tip I know is to not let anyone 1v1 the broom lol.</p>

<p><strong>Review</strong>
TBD :(</p>

<hr>

<h2 id="study-in-marble">Study in Marble</h2>

<p>From the <a href="https://www.dmsguild.com/en/product/408152/a-study-in-marble" rel="nofollow">DMSguild.com page for it</a>. Also was announced <a href="https://www.reddit.com/r/DnDBehindTheScreen/comments/x0t5am/a_study_in_marble_a_mystery_oneshot_based_on/" rel="nofollow">via reddit</a> and they have some tips and suggestions.</p>

<p>The richest man on the isle of Syklos has suddenly gone missing. He’s been known to have some extramarital excursions in the past, but this time is different—he hasn’t come back. Why did he disappear? Who is responsible? And what does the eccentric local sculptor have to do with it?
A Study in Marble is an adventure for a 3rd to 5th level party inspired by ancient Greek mythology. Players will unravel a mystery in an urban environment, with significant emphasis on social interaction and gathering clues; the module can be played as a one-shot or integrated into an existing campaign as a side quest. The adventure is especially suitable for campaigns set in the world of Theros, but can fit into any campaign with room for a Greek city.</p>

<p>This module includes:
– 3 maps, in both PDF and JPG format
– 4 possible endings, depending on the choices made by the party
– 1 central plot twist that will keep your players guessing</p>

<p><strong>Review</strong>:</p>

<p>Roleplay heavy, fun to run.</p>

<hr>

<h2 id="a-wild-sheep-chase">A Wild Sheep Chase</h2>

<p>A Single-Session Adventure for parties of 4th-5th level
The very first adventure produced by Winghorn Press, freshly updated with player feedback and suggestions,
as well as a brand new map. When the party’s attempt to grab a rare afternoon of downtime is interrupted by a frantic sheep equipped with a
Scroll of Speak to Animals, they’re dragged into a magical grudge match that will test their strength, courage and willingness to endure baa’d puns.</p>

<p>Will our heroes be able to overcome a band of transmuted assassins and an extremely bitter apprentice packing dangerously unstable magic items? There’s only one way to find out.</p>

<p><a href="https://winghornpress.com/adventures/a-wild-sheep-chase/" rel="nofollow">Free download here from their site</a></p>

<p><strong>Review</strong>:</p>

<p>Can either be roleplay or combat driven. Good for new players or new DMs. I’ve got some mini’s for this one if you’d like to use them.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/dnd-one-shot-recommendations</guid>
      <pubDate>Thu, 19 Mar 2026 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>Locking yourself out of SDDM with .bashrc</title>
      <link>https://edfig.dev/eddie/locking-yourself-out-of-sddm-with-bashrc</link>
      <description>&lt;![CDATA[Transferring&#xA;&#xA;I’m going to SCaLEx23. I don’t tend to use my laptop as a primary device so I was transferring everything.&#xA;&#xA;I literally can’t live without my aliases and shortcuts so in my rush I somehow moved a copy of my .bashrc into ~/.bashrc.d. Which doesn’t sound like a big deal except I have this in my main file.&#xA;&#xA;if [ -d ~/.bashrc.d ]; then&#xA;for rc in ~/.bashrc.d/*.sh; do&#xA;  if [ -f &#34;$rc&#34; ]; then&#xA;    . &#34;$rc&#34;&#xA;  fi&#xA;done&#xA;fi&#xA;&#xA;Why load everything in? Because I’m lazy.&#xA;&#xA;I find out on next login that I’m stuck in a login-loop. Getting in through TTY3 check the thousands of SDDM error crashing messages in journalctl and remove the rogue file.&#xA;&#xA;The Fix&#xA;&#xA;I’ve since moved everything to only loop over items ending in .sh to avoid this unwanted files being sourced.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<h1 id="transferring">Transferring</h1>

<p>I’m going to <a href="https://www.socallinuxexpo.org/scale/23x" rel="nofollow">SCaLEx23</a>. I don’t tend to use my laptop as a primary device so I was transferring <em>everything</em>.</p>

<p>I literally can’t live without my aliases and shortcuts so in my rush I somehow moved a copy of my <code>.bashrc</code> into <code>~/.bashrc.d</code>. Which doesn’t sound like a big deal except I have this in my main file.</p>

<pre><code class="language-bash">if [ -d ~/.bashrc.d ]; then
for rc in ~/.bashrc.d/*.sh; do
  if [ -f &#34;$rc&#34; ]; then
    . &#34;$rc&#34;
  fi
done
fi
</code></pre>

<p>Why load everything in? Because I’m lazy.</p>

<p>I find out on next login that I’m stuck in a login-loop. Getting in through TTY3 check the thousands of SDDM error crashing messages in <code>journalctl</code> and remove the rogue file.</p>

<h1 id="the-fix">The Fix</h1>

<p>I’ve since moved everything to only loop over items ending in <code>.sh</code> to avoid this unwanted files being sourced.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/locking-yourself-out-of-sddm-with-bashrc</guid>
      <pubDate>Sun, 01 Mar 2026 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>Rice</title>
      <link>https://edfig.dev/eddie/rice</link>
      <description>&lt;![CDATA[I like the fun linux commands that rice out your setup but I don’t like having to remember when/how to use them.&#xA;&#xA;I’ve got my .bashrc that calls everything in .bashrc.d/*. In there I’ve started throwing in files with custom config options.&#xA;&#xA;Here’s a quick ls function that’s context aware. I’ll be expanding it as I learn better ways to use eza or similar listing tools.&#xA;&#xA;alias ls=&#39;ls&#39;&#xA;ls: use eza with git info inside git repos, plain ls elsewhere&#xA;ls() {&#xA;    if git rev-parse --is-inside-work-tree &amp;  /dev/null; then&#xA;        eza -l -h --git --git-repos --total-size --no-user --git-ignore --icons &#34;$@&#34;&#xA;    else&#xA;        command ls &#34;$@&#34;&#xA;    fi&#xA;}&#xA;&#xA;Turns this&#xA;&#xA;figsystems on main&#xA;  11:48 ❯ /usr/bin/ls&#xA;archetypes  content  hugo.yaml  README.md  themes&#xA;&#xA;to this&#xA;&#xA;figsystems on main&#xA;  11:48 ❯ ls&#xA;Permissions Size Date Modified Git Git Repo Name&#xA;drwxr-xr-x@ 1.1k  5 Feb 14:18   -- - -       archetypes&#xA;drwxr-xr-x@  70k  5 Feb 14:18   -- - -       content&#xA;.rw-r--r--@ 3.4k  5 Feb 15:57   -- - -       hugo.yaml&#xA;.rw-r--r--@  237  5 Feb 14:18   -- - -      󰂺 README.md&#xA;drwxr-xr-x@    0  5 Feb 14:18   -- - -       themes&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<p>I like the fun linux commands that rice out your setup but I don’t like having to remember when/how to use them.</p>

<p>I’ve got my <code>.bashrc</code> that calls everything in <code>.bashrc.d/*</code>. In there I’ve started throwing in files with custom config options.</p>

<p>Here’s a quick ls function that’s context aware. I’ll be expanding it as I learn better ways to use eza or similar listing tools.</p>

<pre><code class="language-bash">alias ls=&#39;_ls&#39;
# ls: use eza with git info inside git repos, plain ls elsewhere
_ls() {
    if git rev-parse --is-inside-work-tree &amp;&gt;/dev/null; then
        eza -l -h --git --git-repos --total-size --no-user --git-ignore --icons &#34;$@&#34;
    else
        command ls &#34;$@&#34;
    fi
}
</code></pre>

<p>Turns this</p>

<pre><code class="language-bash">figsystems on main
  11:48 ❯ /usr/bin/ls
archetypes  content  hugo.yaml  README.md  themes
</code></pre>

<p>to this</p>

<pre><code class="language-bash">figsystems on main
  11:48 ❯ ls
Permissions Size Date Modified Git Git Repo Name
drwxr-xr-x@ 1.1k  5 Feb 14:18   -- - -       archetypes
drwxr-xr-x@  70k  5 Feb 14:18   -- - -       content
.rw-r--r--@ 3.4k  5 Feb 15:57   -- - -       hugo.yaml
.rw-r--r--@  237  5 Feb 14:18   -- - -      󰂺 README.md
drwxr-xr-x@    0  5 Feb 14:18   -- - -       themes
</code></pre>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/rice</guid>
      <pubDate>Tue, 24 Feb 2026 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>Formatting AWS Security Groups for a VMware Migration</title>
      <link>https://edfig.dev/eddie/formatting-aws-security-groups-for-a-vmware-migration</link>
      <description>&lt;![CDATA[The Problem&#xA;&#xA;At work we’re in the middle of a large lift and shift migration from VMware to AWS (for the same reason everyone is). Hundreds of servers across multiple departments, moved in waves.&#xA;&#xA;The firewall rules for these servers come from everywhere. Palo Alto firewalls, host-based firewalls, department-specific switches, department-specific IT teams, random appliances that predate much of the current staff. Years of accumulated rules from multiple sources, and now they all need to become AWS security groups.&#xA;&#xA;I needed to figure out how to format these rules in Terraform so that:&#xA;Coworkers completely new to IaC could read them&#xA;I could maintain them without losing my mind as rule counts climbed&#xA;PRs were reviewable&#xA;&#xA;This is how the format evolved over three iterations.&#xA;&#xA;Iteration 1: Inline Rules&#xA;&#xA;The most straightforward way to write a security group. Everything in one block.&#xA;&#xA;resource &#34;awssecuritygroup&#34; &#34;webserver&#34; {&#xA;  name        = &#34;web-server&#34;&#xA;  description = &#34;SG for web-server&#34;&#xA;  vpcid      = var.vpcid&#xA;&#xA;  ingress {&#xA;    description = &#34;HTTPS from campus&#34;&#xA;    fromport   = 443&#xA;    toport     = 443&#xA;    protocol    = &#34;tcp&#34;&#xA;    cidrblocks = [&#34;10.0.0.0/24&#34;]&#xA;  }&#xA;&#xA;  ingress {&#xA;    description = &#34;SSH from admin subnet&#34;&#xA;    fromport   = 22&#xA;    toport     = 22&#xA;    protocol    = &#34;tcp&#34;&#xA;    cidrblocks = [&#34;10.100.0.0/24&#34;]&#xA;  }&#xA;&#xA;  egress {&#xA;    description = &#34;Allow all outbound&#34;&#xA;    fromport   = 0&#xA;    toport     = 0&#xA;    protocol    = &#34;-1&#34;&#xA;    cidrblocks = [&#34;0.0.0.0/0&#34;]&#xA;  }&#xA;}&#xA;&#xA;This works fine for a server with 3-4 rules and is the first example you usually come across if you search for “ec2 firewalls”. It’s easy to read and easy to explain to someone who’s never seen Terraform before.&#xA;&#xA;The problem is that any change to any inline rule forces Terraform to evaluate the entire security group. Add a CIDR to one ingress block and the plan output gets noisy. It also doesn’t play well with foreach if you want to loop over CIDRs for a single port.&#xA;&#xA;Iteration 2: Separate Rule Resources&#xA;&#xA;Breaking the rules out into their own resources using awsvpcsecuritygroupingressrule and awsvpcsecuritygroupegressrule.&#xA;&#xA;resource &#34;awssecuritygroup&#34; &#34;webserver&#34; {&#xA;  description = &#34;SG for web-server&#34;&#xA;  vpcid      = var.vpcid&#xA;&#xA;  tags = {&#xA;    Name   = &#34;web-server&#34;&#xA;    Source = &#34;Palo Alto Firewall&#34;&#xA;  }&#xA;}&#xA;&#xA;Egress&#xA;resource &#34;awsvpcsecuritygroupegressrule&#34; &#34;webserverallowalloutbound&#34; {&#xA;  securitygroupid = awssecuritygroup.webserver.id&#xA;  ipprotocol       = &#34;-1&#34;&#xA;  cidripv4         = &#34;0.0.0.0/0&#34;&#xA;&#xA;  tags = {&#xA;    Name = &#34;allow-all-outbound&#34;&#xA;  }&#xA;}&#xA;&#xA;HTTPS from campus&#xA;resource &#34;awsvpcsecuritygroupingressrule&#34; &#34;webserverhttps443&#34; {&#xA;  foreach          = var.https443cidrs&#xA;  securitygroupid = awssecuritygroup.webserver.id&#xA;  cidripv4         = each.key&#xA;  description       = each.value&#xA;  ipprotocol       = &#34;tcp&#34;&#xA;  fromport         = 443&#xA;  toport           = 443&#xA;&#xA;  tags = {&#xA;    Name = &#34;HTTPS-443-${replace(each.key, &#34;/&#34;, &#34;-&#34;)}&#34;&#xA;    Rule = &#34;tcp-443&#34;&#xA;  }&#xA;}&#xA;&#xA;SSH from admin subnet&#xA;resource &#34;awsvpcsecuritygroupingressrule&#34; &#34;webserverssh22&#34; {&#xA;  foreach          = var.ssh22cidrs&#xA;  securitygroupid = awssecuritygroup.webserver.id&#xA;  cidripv4         = each.key&#xA;  description       = each.value&#xA;  ipprotocol       = &#34;tcp&#34;&#xA;  fromport         = 22&#xA;  toport           = 22&#xA;&#xA;  tags = {&#xA;    Name = &#34;SSH-22-${replace(each.key, &#34;/&#34;, &#34;-&#34;)}&#34;&#xA;    Rule = &#34;tcp-22&#34;&#xA;  }&#xA;}&#xA;&#xA;With variables like:&#xA;&#xA;variable &#34;https443cidrs&#34; {&#xA;  type = map(string)&#xA;  default = {&#xA;    &#34;10.0.0.0/24&#34;   = &#34;Campus network&#34;&#xA;    &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;&#xA;  }&#xA;}&#xA;&#xA;variable &#34;ssh22cidrs&#34; {&#xA;  type = map(string)&#xA;  default = {&#xA;    &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;&#xA;  }&#xA;}&#xA;&#xA;This is better. Each rule is its own resource so Terraform plans are cleaner. Adding a CIDR to a port only shows that one rule changing. The foreach on a map of CIDR-to-description means you can see at a glance what each IP range is for.&#xA;&#xA;I used this format for the 2nd wave. It worked. But by the next few waves we were moving more servers per wave and each server had its own set of variables. The variable files were getting long and hard to cross-reference with the rules.&#xA;&#xA;Everything was also moved into a $WORKSPACE/modules/security-groups/ directory to keep it organized. One file per server’s rules, one file per server’s variables.&#xA;&#xA;Iteration 3: Locals with Structured Data&#xA;&#xA;By the time we were moving double digit servers per wave, the variable-per-port approach was getting hard to maintain. Too many variable files, too much scrolling back and forth to understand what a server’s rules actually looked like.&#xA;&#xA;I switched to using locals with a structured list. All the rules for a server live in one block. Each entry defines the port, protocol, and every CIDR that needs access on that port.&#xA;&#xA;locals {&#xA;  webserverports = [&#xA;    # HTTPS&#xA;    {&#xA;      protocol = &#34;tcp&#34;&#xA;      from     = 443&#xA;      to       = 443&#xA;      name     = &#34;https-443&#34;&#xA;      cidrs = {&#xA;        &#34;10.0.0.0/24&#34;   = &#34;Campus network&#34;&#xA;        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;&#xA;      }&#xA;    },&#xA;    # SSH&#xA;    {&#xA;      protocol = &#34;tcp&#34;&#xA;      from     = 22&#xA;      to       = 22&#xA;      name     = &#34;ssh-22&#34;&#xA;      cidrs = {&#xA;        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;&#xA;      }&#xA;    },&#xA;    # RDP&#xA;    {&#xA;      protocol = &#34;tcp&#34;&#xA;      from     = 3389&#xA;      to       = 3389&#xA;      name     = &#34;rdp-3389&#34;&#xA;      cidrs = {&#xA;        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;&#xA;      }&#xA;    },&#xA;    # HTTP&#xA;    {&#xA;      protocol = &#34;tcp&#34;&#xA;      from     = 80&#xA;      to       = 80&#xA;      name     = &#34;http-80&#34;&#xA;      cidrs = {&#xA;        &#34;10.0.0.0/24&#34; = &#34;Campus network&#34;&#xA;      }&#xA;    },&#xA;  ]&#xA;&#xA;  # Flatten into individual rules&#xA;  webserverrules = flatten([&#xA;    for portconfig in local.webserverports : [&#xA;      for cidr, description in portconfig.cidrs : {&#xA;        key         = &#34;${portconfig.name}-${replace(cidr, &#34;/&#34;, &#34;-&#34;)}&#34;&#xA;        protocol    = portconfig.protocol&#xA;        fromport   = portconfig.from&#xA;        toport     = portconfig.to&#xA;        cidr        = cidr&#xA;        description = description&#xA;        rulename   = portconfig.name&#xA;      }&#xA;    ]&#xA;  ])&#xA;&#xA;  # How many rules total&#xA;  webservertotalrulecount = length(local.webserverrules)&#xA;&#xA;  # How many SGs needed (AWS has a rules-per-SG limit)&#xA;  webserversgcount = max(1, ceil(local.webservertotalrulecount / var.maxrulespersg))&#xA;&#xA;  # Chunk rules across SGs&#xA;  webserverruleschunked = {&#xA;    for sgindex in range(local.webserversgcount) : sgindex =  [&#xA;      for ruleindex in range(&#xA;        sgindex  var.maxrulespersg,&#xA;        min((sgindex + 1)  var.maxrulespersg, local.webservertotalrulecount)&#xA;      ) : local.webserverrules[ruleindex]&#xA;    ]&#xA;  }&#xA;}&#xA;&#xA;The security group itself handles overflow automatically. If a server has more rules than AWS allows per SG, it creates additional SGs and distributes the rules across them. Neither I nor anyone in my team had to count rules to make sure they were split across security groups evenly. It all gets generated dynamically.&#xA;&#xA;Primary SG&#xA;resource &#34;awssecuritygroup&#34; &#34;webserver&#34; {&#xA;  name        = &#34;web-server&#34;&#xA;  description = &#34;SG for web-server&#34;&#xA;  vpcid      = var.vpcid&#xA;&#xA;  lifecycle {&#xA;    createbeforedestroy = true&#xA;  }&#xA;&#xA;  tags = {&#xA;    Name = &#34;web-server&#34;&#xA;  }&#xA;}&#xA;&#xA;Overflow SGs (created only if needed)&#xA;resource &#34;awssecuritygroup&#34; &#34;webserveroverflow&#34; {&#xA;  foreach = { for idx in range(1, local.webserversgcount) : idx =  idx }&#xA;&#xA;  name        = &#34;web-server-overflow-${each.value}&#34;&#xA;  description = &#34;SG for web-server (Overflow ${each.value})&#34;&#xA;  vpcid      = var.vpcid&#xA;&#xA;  lifecycle {&#xA;    createbeforedestroy = true&#xA;  }&#xA;&#xA;  tags = {&#xA;    Name = &#34;web-server-overflow-${each.value}&#34;&#xA;  }&#xA;}&#xA;&#xA;Egress (primary SG only)&#xA;resource &#34;awsvpcsecuritygroupegressrule&#34; &#34;webserverallowalloutbound&#34; {&#xA;  securitygroupid = awssecuritygroup.webserver.id&#xA;  ipprotocol       = &#34;-1&#34;&#xA;  cidripv4         = &#34;0.0.0.0/0&#34;&#xA;&#xA;  tags = {&#xA;    Name = &#34;allow-all-outbound&#34;&#xA;  }&#xA;}&#xA;&#xA;Ingress for primary SG&#xA;resource &#34;awsvpcsecuritygroupingressrule&#34; &#34;webserveringress&#34; {&#xA;  foreach = {&#xA;    for rule in local.webserverruleschunked[0] :&#xA;    rule.key =  rule&#xA;  }&#xA;&#xA;  securitygroupid = awssecuritygroup.webserver.id&#xA;  cidripv4         = each.value.cidr&#xA;  description       = each.value.description&#xA;  ipprotocol       = each.value.protocol&#xA;  fromport         = each.value.protocol == &#34;-1&#34; ? null : each.value.fromport&#xA;  toport           = each.value.protocol == &#34;-1&#34; ? null : each.value.toport&#xA;&#xA;  tags = {&#xA;    Name = each.value.key&#xA;    Rule = each.value.rulename&#xA;  }&#xA;}&#xA;&#xA;Ingress for overflow SGs&#xA;resource &#34;awsvpcsecuritygroupingressrule&#34; &#34;webserveroverflowingress&#34; {&#xA;  foreach = merge([&#xA;    for sgindex, sg in awssecuritygroup.webserveroverflow : {&#xA;      for rule in local.webserverruleschunked[sgindex] :&#xA;      &#34;${sgindex}-${rule.key}&#34; =  {&#xA;        sgid       = sg.id&#xA;        cidr        = rule.cidr&#xA;        description = rule.description&#xA;        protocol    = rule.protocol&#xA;        fromport   = rule.fromport&#xA;        toport     = rule.toport&#xA;        key         = rule.key&#xA;        rulename   = rule.rulename&#xA;      }&#xA;    }&#xA;  ]...)&#xA;&#xA;  securitygroupid = each.value.sgid&#xA;  cidripv4         = each.value.cidr&#xA;  description       = each.value.description&#xA;  ipprotocol       = each.value.protocol&#xA;  fromport         = each.value.protocol == &#34;-1&#34; ? null : each.value.fromport&#xA;  toport           = each.value.protocol == &#34;-1&#34; ? null : each.value.toport&#xA;&#xA;  tags = {&#xA;    Name = each.value.key&#xA;    Rule = each.value.rulename&#xA;  }&#xA;}&#xA;&#xA;Adding a new server means copying the template, doing a find-and-replace on the server name, and filling in the ports list. The SG resource, egress, overflow, and ingress logic are all identical across servers. The only thing that changes is the data in locals.&#xA;&#xA;The big win for PR reviews is that the ports local reads like a table. You can look at it and immediately see what ports are open and to whom without having to mentally reconstruct it from scattered variable files.&#xA;&#xA;Standard Security Groups&#xA;&#xA;While all the above handles per-server rules, we noticed early on that a lot of rules were the same across every server. RDP from the admin subnet, SSH from the admin subnet, ICMP from campus, etc. Every single server had these and we were duplicating them everywhere.&#xA;&#xA;So we created a separate shared module: $ROOTOFMONOREPO/modules/standard-securitygroups. It only takes a vpcid as input and creates a set of reusable security groups that any server can reference.&#xA;&#xA;It does stuff like create our 3 admin groups:&#xA;defaultadmin — ICMP and monitoring/backup access. No remote access.&#xA;linuxadmin - SSH mostly&#xA;windowsadmin - All the lovely SCCM/WSUS/SMB cruft from admin networks.&#xA;&#xA;The key difference from per-server groups is that it uses managed prefix lists to centralize the IP ranges. Instead of hardcoding CIDRs in every rule, the rules reference a prefix list.&#xA;&#xA;resource &#34;awsec2managedprefixlist&#34; &#34;linuxadminaccess&#34; {&#xA;  name           = &#34;server-admin-access&#34;&#xA;  addressfamily = &#34;IPv4&#34;&#xA;  maxentries    = 5&#xA;&#xA;  entry {&#xA;    cidr        = &#34;10.0.0.0/24&#34;&#xA;    description = &#34;Dept A linux Admin&#34;&#xA;  }&#xA;&#xA;  entry {&#xA;    cidr        = &#34;10.100.0.0/24&#34;&#xA;    description = &#34;Dept B linux Admin&#34;&#xA;  }&#xA;}&#xA;&#xA;Then the rules reference the prefix list instead of individual CIDRs:&#xA;&#xA;resource &#34;awsvpcsecuritygroupingressrule&#34; &#34;linuxadminssh&#34; {&#xA;  securitygroupid = awssecuritygroup.linuxadmin.id&#xA;  prefixlistid    = awsec2managedprefixlist.serveradminaccess.id&#xA;  ipprotocol       = &#34;tcp&#34;&#xA;  fromport         = 22&#xA;  toport           = 22&#xA;&#xA;  tags = {&#xA;    Name = &#34;SSH-22-admin-access&#34;&#xA;  }&#xA;}&#xA;&#xA;When a new admin subnet needs access, you add one entry to the prefix list and every security group that references it picks it up. No touching individual server rules.&#xA;&#xA;A server ends up with its per-server SG for application-specific rules and one or more standard SGs for the common stuff:&#xA;&#xA;vpcsecuritygroupids = [&#xA;  module.securitygroups.webserversgid,&#xA;  module.standardsecuritygroups.windowsadminsecuritygroupid&#xA;]&#xA;&#xA;This keeps the per-server rule files focused on what’s actually unique to that server.&#xA;&#xA;What’s Next&#xA;&#xA;The standard module handles the baseline admin access that every server gets. The next step is creating standard service-level and department-service-level SGs.&#xA;&#xA;A generic db-sg would cover common database ports that most database servers need. But a math-db-sg would layer on department-specific rules for the math department’s network ranges, their specific application servers, and their particular inter-database communication patterns. Same idea for web servers, app servers, etc.&#xA;&#xA;The goal is to get to a point where standing up a new server means picking from a menu of standard SGs rather than writing rules from scratch every time.&#xA;&#xA;What I’d Do Differently&#xA;&#xA;Not much honestly. The progression made sense given the constraints. We didn’t know how many servers we’d be moving per wave at the start and the format evolved as the workload scaled. The template approach with find-and-replace is simple enough that even the folks brand new to Terraform are following along.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<h1 id="the-problem">The Problem</h1>

<p>At work we’re in the middle of a large lift and shift migration from VMware to AWS (for the same reason everyone is). Hundreds of servers across multiple departments, moved in waves.</p>

<p>The firewall rules for these servers come from everywhere. Palo Alto firewalls, host-based firewalls, department-specific switches, department-specific IT teams, random appliances that predate much of the current staff. Years of accumulated rules from multiple sources, and now they all need to become AWS security groups.</p>

<p>I needed to figure out how to format these rules in Terraform so that:
– Coworkers completely new to IaC could read them
– I could maintain them without losing my mind as rule counts climbed
– PRs were reviewable</p>

<p>This is how the format evolved over three iterations.</p>

<h1 id="iteration-1-inline-rules">Iteration 1: Inline Rules</h1>

<p>The most straightforward way to write a security group. Everything in one block.</p>

<pre><code class="language-hcl">resource &#34;aws_security_group&#34; &#34;web_server&#34; {
  name        = &#34;web-server&#34;
  description = &#34;SG for web-server&#34;
  vpc_id      = var.vpc_id

  ingress {
    description = &#34;HTTPS from campus&#34;
    from_port   = 443
    to_port     = 443
    protocol    = &#34;tcp&#34;
    cidr_blocks = [&#34;10.0.0.0/24&#34;]
  }

  ingress {
    description = &#34;SSH from admin subnet&#34;
    from_port   = 22
    to_port     = 22
    protocol    = &#34;tcp&#34;
    cidr_blocks = [&#34;10.100.0.0/24&#34;]
  }

  egress {
    description = &#34;Allow all outbound&#34;
    from_port   = 0
    to_port     = 0
    protocol    = &#34;-1&#34;
    cidr_blocks = [&#34;0.0.0.0/0&#34;]
  }
}
</code></pre>

<p>This works fine for a server with 3-4 rules and is the first example you usually come across if you search for “ec2 firewalls”. It’s easy to read and easy to explain to someone who’s never seen Terraform before.</p>

<p>The problem is that any change to any inline rule forces Terraform to evaluate the entire security group. Add a CIDR to one ingress block and the plan output gets noisy. It also doesn’t play well with <code>for_each</code> if you want to loop over CIDRs for a single port.</p>

<h1 id="iteration-2-separate-rule-resources">Iteration 2: Separate Rule Resources</h1>

<p>Breaking the rules out into their own resources using <code>aws_vpc_security_group_ingress_rule</code> and <code>aws_vpc_security_group_egress_rule</code>.</p>

<pre><code class="language-hcl">resource &#34;aws_security_group&#34; &#34;web_server&#34; {
  description = &#34;SG for web-server&#34;
  vpc_id      = var.vpc_id

  tags = {
    Name   = &#34;web-server&#34;
    Source = &#34;Palo Alto Firewall&#34;
  }
}

# Egress
resource &#34;aws_vpc_security_group_egress_rule&#34; &#34;web_server_allow_all_outbound&#34; {
  security_group_id = aws_security_group.web_server.id
  ip_protocol       = &#34;-1&#34;
  cidr_ipv4         = &#34;0.0.0.0/0&#34;

  tags = {
    Name = &#34;allow-all-outbound&#34;
  }
}

# HTTPS from campus
resource &#34;aws_vpc_security_group_ingress_rule&#34; &#34;web_server_https_443&#34; {
  for_each          = var.https_443_cidrs
  security_group_id = aws_security_group.web_server.id
  cidr_ipv4         = each.key
  description       = each.value
  ip_protocol       = &#34;tcp&#34;
  from_port         = 443
  to_port           = 443

  tags = {
    Name = &#34;HTTPS-443-${replace(each.key, &#34;/&#34;, &#34;-&#34;)}&#34;
    Rule = &#34;tcp-443&#34;
  }
}

# SSH from admin subnet
resource &#34;aws_vpc_security_group_ingress_rule&#34; &#34;web_server_ssh_22&#34; {
  for_each          = var.ssh_22_cidrs
  security_group_id = aws_security_group.web_server.id
  cidr_ipv4         = each.key
  description       = each.value
  ip_protocol       = &#34;tcp&#34;
  from_port         = 22
  to_port           = 22

  tags = {
    Name = &#34;SSH-22-${replace(each.key, &#34;/&#34;, &#34;-&#34;)}&#34;
    Rule = &#34;tcp-22&#34;
  }
}
</code></pre>

<p>With variables like:</p>

<pre><code class="language-hcl">variable &#34;https_443_cidrs&#34; {
  type = map(string)
  default = {
    &#34;10.0.0.0/24&#34;   = &#34;Campus network&#34;
    &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;
  }
}

variable &#34;ssh_22_cidrs&#34; {
  type = map(string)
  default = {
    &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;
  }
}
</code></pre>

<p>This is better. Each rule is its own resource so Terraform plans are cleaner. Adding a CIDR to a port only shows that one rule changing. The <code>for_each</code> on a map of CIDR-to-description means you can see at a glance what each IP range is for.</p>

<p>I used this format for the 2nd wave. It worked. But by the next few waves we were moving more servers per wave and each server had its own set of variables. The variable files were getting long and hard to cross-reference with the rules.</p>

<p>Everything was also moved into a <code>$WORKSPACE/modules/security-groups/</code> directory to keep it organized. One file per server’s rules, one file per server’s variables.</p>

<h1 id="iteration-3-locals-with-structured-data">Iteration 3: Locals with Structured Data</h1>

<p>By the time we were moving double digit servers per wave, the variable-per-port approach was getting hard to maintain. Too many variable files, too much scrolling back and forth to understand what a server’s rules actually looked like.</p>

<p>I switched to using <code>locals</code> with a structured list. All the rules for a server live in one block. Each entry defines the port, protocol, and every CIDR that needs access on that port.</p>

<pre><code class="language-hcl">locals {
  web_server_ports = [
    # HTTPS
    {
      protocol = &#34;tcp&#34;
      from     = 443
      to       = 443
      name     = &#34;https-443&#34;
      cidrs = {
        &#34;10.0.0.0/24&#34;   = &#34;Campus network&#34;
        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;
      }
    },
    # SSH
    {
      protocol = &#34;tcp&#34;
      from     = 22
      to       = 22
      name     = &#34;ssh-22&#34;
      cidrs = {
        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;
      }
    },
    # RDP
    {
      protocol = &#34;tcp&#34;
      from     = 3389
      to       = 3389
      name     = &#34;rdp-3389&#34;
      cidrs = {
        &#34;10.100.0.0/24&#34; = &#34;Admin subnet&#34;
      }
    },
    # HTTP
    {
      protocol = &#34;tcp&#34;
      from     = 80
      to       = 80
      name     = &#34;http-80&#34;
      cidrs = {
        &#34;10.0.0.0/24&#34; = &#34;Campus network&#34;
      }
    },
  ]

  # Flatten into individual rules
  web_server_rules = flatten([
    for port_config in local.web_server_ports : [
      for cidr, description in port_config.cidrs : {
        key         = &#34;${port_config.name}-${replace(cidr, &#34;/&#34;, &#34;-&#34;)}&#34;
        protocol    = port_config.protocol
        from_port   = port_config.from
        to_port     = port_config.to
        cidr        = cidr
        description = description
        rule_name   = port_config.name
      }
    ]
  ])

  # How many rules total
  web_server_total_rule_count = length(local.web_server_rules)

  # How many SGs needed (AWS has a rules-per-SG limit)
  web_server_sg_count = max(1, ceil(local.web_server_total_rule_count / var.max_rules_per_sg))

  # Chunk rules across SGs
  web_server_rules_chunked = {
    for sg_index in range(local.web_server_sg_count) : sg_index =&gt; [
      for rule_index in range(
        sg_index * var.max_rules_per_sg,
        min((sg_index + 1) * var.max_rules_per_sg, local.web_server_total_rule_count)
      ) : local.web_server_rules[rule_index]
    ]
  }
}
</code></pre>

<p>The security group itself handles overflow automatically. If a server has more rules than AWS allows per SG, it creates additional SGs and distributes the rules across them. Neither I nor anyone in my team had to count rules to make sure they were split across security groups evenly. It all gets generated dynamically.</p>

<pre><code class="language-hcl"># Primary SG
resource &#34;aws_security_group&#34; &#34;web_server&#34; {
  name        = &#34;web-server&#34;
  description = &#34;SG for web-server&#34;
  vpc_id      = var.vpc_id

  lifecycle {
    create_before_destroy = true
  }

  tags = {
    Name = &#34;web-server&#34;
  }
}

# Overflow SGs (created only if needed)
resource &#34;aws_security_group&#34; &#34;web_server_overflow&#34; {
  for_each = { for idx in range(1, local.web_server_sg_count) : idx =&gt; idx }

  name        = &#34;web-server-overflow-${each.value}&#34;
  description = &#34;SG for web-server (Overflow ${each.value})&#34;
  vpc_id      = var.vpc_id

  lifecycle {
    create_before_destroy = true
  }

  tags = {
    Name = &#34;web-server-overflow-${each.value}&#34;
  }
}

# Egress (primary SG only)
resource &#34;aws_vpc_security_group_egress_rule&#34; &#34;web_server_allow_all_outbound&#34; {
  security_group_id = aws_security_group.web_server.id
  ip_protocol       = &#34;-1&#34;
  cidr_ipv4         = &#34;0.0.0.0/0&#34;

  tags = {
    Name = &#34;allow-all-outbound&#34;
  }
}

# Ingress for primary SG
resource &#34;aws_vpc_security_group_ingress_rule&#34; &#34;web_server_ingress&#34; {
  for_each = {
    for rule in local.web_server_rules_chunked[0] :
    rule.key =&gt; rule
  }

  security_group_id = aws_security_group.web_server.id
  cidr_ipv4         = each.value.cidr
  description       = each.value.description
  ip_protocol       = each.value.protocol
  from_port         = each.value.protocol == &#34;-1&#34; ? null : each.value.from_port
  to_port           = each.value.protocol == &#34;-1&#34; ? null : each.value.to_port

  tags = {
    Name = each.value.key
    Rule = each.value.rule_name
  }
}

# Ingress for overflow SGs
resource &#34;aws_vpc_security_group_ingress_rule&#34; &#34;web_server_overflow_ingress&#34; {
  for_each = merge([
    for sg_index, sg in aws_security_group.web_server_overflow : {
      for rule in local.web_server_rules_chunked[sg_index] :
      &#34;${sg_index}-${rule.key}&#34; =&gt; {
        sg_id       = sg.id
        cidr        = rule.cidr
        description = rule.description
        protocol    = rule.protocol
        from_port   = rule.from_port
        to_port     = rule.to_port
        key         = rule.key
        rule_name   = rule.rule_name
      }
    }
  ]...)

  security_group_id = each.value.sg_id
  cidr_ipv4         = each.value.cidr
  description       = each.value.description
  ip_protocol       = each.value.protocol
  from_port         = each.value.protocol == &#34;-1&#34; ? null : each.value.from_port
  to_port           = each.value.protocol == &#34;-1&#34; ? null : each.value.to_port

  tags = {
    Name = each.value.key
    Rule = each.value.rule_name
  }
}
</code></pre>

<p>Adding a new server means copying the template, doing a find-and-replace on the server name, and filling in the <code>ports</code> list. The SG resource, egress, overflow, and ingress logic are all identical across servers. The only thing that changes is the data in <code>locals</code>.</p>

<p>The big win for PR reviews is that the <code>ports</code> local reads like a table. You can look at it and immediately see what ports are open and to whom without having to mentally reconstruct it from scattered variable files.</p>

<h1 id="standard-security-groups">Standard Security Groups</h1>

<p>While all the above handles per-server rules, we noticed early on that a lot of rules were the same across every server. RDP from the admin subnet, SSH from the admin subnet, ICMP from campus, etc. Every single server had these and we were duplicating them everywhere.</p>

<p>So we created a separate shared module: <code>$ROOT_OF_MONOREPO/modules/standard-securitygroups</code>. It only takes a <code>vpc_id</code> as input and creates a set of reusable security groups that any server can reference.</p>

<p>It does stuff like create our 3 admin groups:
– <strong>default_admin</strong> — ICMP and monitoring/backup access. No remote access.
– <strong>linux_admin</strong> – SSH mostly
– <strong>windows_admin</strong> – All the lovely SCCM/WSUS/SMB cruft from admin networks.</p>

<p>The key difference from per-server groups is that it uses managed prefix lists to centralize the IP ranges. Instead of hardcoding CIDRs in every rule, the rules reference a prefix list.</p>

<pre><code class="language-hcl">resource &#34;aws_ec2_managed_prefix_list&#34; &#34;linux_admin_access&#34; {
  name           = &#34;server-admin-access&#34;
  address_family = &#34;IPv4&#34;
  max_entries    = 5

  entry {
    cidr        = &#34;10.0.0.0/24&#34;
    description = &#34;Dept A linux Admin&#34;
  }

  entry {
    cidr        = &#34;10.100.0.0/24&#34;
    description = &#34;Dept B linux Admin&#34;
  }
}
</code></pre>

<p>Then the rules reference the prefix list instead of individual CIDRs:</p>

<pre><code class="language-hcl">resource &#34;aws_vpc_security_group_ingress_rule&#34; &#34;linux_admin_ssh&#34; {
  security_group_id = aws_security_group.linux_admin.id
  prefix_list_id    = aws_ec2_managed_prefix_list.server_admin_access.id
  ip_protocol       = &#34;tcp&#34;
  from_port         = 22
  to_port           = 22

  tags = {
    Name = &#34;SSH-22-admin-access&#34;
  }
}
</code></pre>

<p>When a new admin subnet needs access, you add one entry to the prefix list and every security group that references it picks it up. No touching individual server rules.</p>

<p>A server ends up with its per-server SG for application-specific rules and one or more standard SGs for the common stuff:</p>

<pre><code class="language-hcl">vpc_security_group_ids = [
  module.security_groups.web_server_sg_id,
  module.standard_securitygroups.windows_admin_security_group_id
]
</code></pre>

<p>This keeps the per-server rule files focused on what’s actually unique to that server.</p>

<h1 id="what-s-next">What’s Next</h1>

<p>The standard module handles the baseline admin access that every server gets. The next step is creating standard service-level and department-service-level SGs.</p>

<p>A generic <code>db-sg</code> would cover common database ports that most database servers need. But a <code>math-db-sg</code> would layer on department-specific rules for the math department’s network ranges, their specific application servers, and their particular inter-database communication patterns. Same idea for web servers, app servers, etc.</p>

<p>The goal is to get to a point where standing up a new server means picking from a menu of standard SGs rather than writing rules from scratch every time.</p>

<h1 id="what-i-d-do-differently">What I’d Do Differently</h1>

<p>Not much honestly. The progression made sense given the constraints. We didn’t know how many servers we’d be moving per wave at the start and the format evolved as the workload scaled. The template approach with find-and-replace is simple enough that even the folks brand new to Terraform are following along.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/formatting-aws-security-groups-for-a-vmware-migration</guid>
      <pubDate>Wed, 05 Feb 2025 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>Bypassing RoyalRoad</title>
      <link>https://edfig.dev/eddie/bypassing-royalroad</link>
      <description>&lt;![CDATA[Issue&#xA;&#xA;Royal Road likes to annoy pirates. This is (arguably) good.&#xA;&#xA;Royal Road doesn’t care if they annoy RSS users. This is bad.&#xA;&#xA;Here’s a walkthrough of the problem and the fix.&#xA;&#xA;The Problem:&#xA;&#xA;First, let’s look at the full picture of why this is happening.&#xA;&#xA;The Original Website HTML (Simplified)&#xA;&#xA;When you visit the Royal Road chapter in your browser, the full page’s HTML looks something like this. Your browser loads thesection and the section.&#xA;&#xA;html&#xA;head&#xA;    style&#xA;        .cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl {&#xA;            display: none;&#xA;        }&#xA;    /style&#xA;/head&#xA;&#xA;...&#xA;&#xA;body&#xA;    div class=&#34;chapter-content&#34;&#xA;&#xA;        p class=&#34;cnMxYzY0ZjllNmVj...&#34;&#xA;            span style=&#34;font-weight: 400&#34;Nathan got the message.../span&#xA;        /p&#xA;&#xA;        p class=&#34;cnNiYTMwZmE4YjE2...&#34; /p&#xA;&#xA;        p class=&#34;cnNiOWQ0MDU1MDA2...&#34;&#xA;            span style=&#34;font-weight: 400&#34;Sarya waved her hand.../span&#xA;        /p&#xA;&#xA;        p class=&#34;cnM0NjAwNWU4Y2Vl...&#34; /p&#xA;&#xA;        span class=&#34;cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl&#34;&#xA;            brThe narrative has been stolen; if detected on Amazon, report...br&#xA;        /span&#xA;&#xA;    /div&#xA;&#xA;    /body&#xA; /html&#xA;&#xA;On the live website, your browser reads the style tag in the head and knows to hide the spam span. You never see it.&#xA;&#xA;What FreshRSS Sees (The Problem)&#xA;&#xA;I’ve told FreshRSS to only grab the content from .chapter-content which is the actual content of a post. So, FreshRSS requests the page and then scrapes only this part:&#xA;&#xA;p class=&#34;cnMxYzY0ZjllNmVj...&#34;&#xA;    span style=&#34;font-weight: 400&#34;Nathan got the message.../span&#xA;/p&#xA;&#xA;p class=&#34;cnNiYTMwZmE4YjE2...&#34; /p&#xA;&#xA;p class=&#34;cnNiOWQ0MDU1MDA2...&#34;&#xA;    span style=&#34;font-weight: 400&#34;Sarya waved her hand.../span&#xA;/p&#xA;&#xA;p class=&#34;cnM0NjAwNWU4Y2Vl...&#34; /p&#xA;&#xA;span class=&#34;cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl&#34;&#xA;    brThe narrative has been stolen; if detected on Amazon, report...br&#xA;/span&#xA;&#xA;Since FreshRSS never saw the head or the style tag, it has no idea it’s supposed to hide the spam span. It just displays all the text it found, resulting in this output in your feed reader:&#xA;&#xA;Nathan got the message...&#xA;&#xA;Sarya waved her hand...&#xA;&#xA;The narrative has been stolen; if detected on Amazon, report...&#xA;&#xA;This is the core of the issue: the content is hidden by a CSS rule that FreshRSS isn’t loading, and the class names are random, so you can’t just block the class.&#xA;&#xA;The Fix: CSS Selectors&#xA;&#xA;You need to tell FreshRSS how to remove the unwanted elements based on their structure, not their random class names.&#xA;&#xA;Go to: Advanced -  CSS selector of the elements to remove.&#xA;Paste this in the box:&#xA;&#xA;.chapter-content   span&#xA;&#xA;This selector targets any span element that is a direct child (using   ) of .chapter-content.&#xA;&#xA;The spam text span class=&#34;cjZhY...&#34;.../span matches this rule.&#xA;&#xA;The actual story text span style=&#34;font-weight: 400&#34;.../span is safe because it’s a “grandchild” (it’s inside a p tag), not a direct child.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<h1 id="issue">Issue</h1>

<p><a href="https://www.royalroad.com/home" rel="nofollow">Royal Road</a> likes to annoy pirates. This is (arguably) good.</p>

<p>Royal Road doesn’t care if they annoy RSS users. This is <strong>bad</strong>.</p>

<p>Here’s a walkthrough of the problem and the fix.</p>

<h3 id="the-problem">The Problem:</h3>

<p>First, let’s look at the full picture of why this is happening.</p>

<p>The Original Website HTML (Simplified)</p>

<p>When you visit the Royal Road chapter in your browser, the full page’s HTML looks something like this. Your browser loads thesection and the section.</p>

<pre><code class="language-HTML">
&lt;html&gt;
&lt;head&gt;
    &lt;style&gt;
        .cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl {
            display: none;
        }
    &lt;/style&gt;
&lt;/head&gt;

...

&lt;body&gt;
    &lt;div class=&#34;chapter-content&#34;&gt;

        &lt;p class=&#34;cnMxYzY0ZjllNmVj...&#34;&gt;
            &lt;span style=&#34;font-weight: 400&#34;&gt;Nathan got the message...&lt;/span&gt;
        &lt;/p&gt;

        &lt;p class=&#34;cnNiYTMwZmE4YjE2...&#34;&gt; &lt;/p&gt;

        &lt;p class=&#34;cnNiOWQ0MDU1MDA2...&#34;&gt;
            &lt;span style=&#34;font-weight: 400&#34;&gt;Sarya waved her hand...&lt;/span&gt;
        &lt;/p&gt;

        &lt;p class=&#34;cnM0NjAwNWU4Y2Vl...&#34;&gt; &lt;/p&gt;

        &lt;span class=&#34;cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl&#34;&gt;
            &lt;br&gt;The narrative has been stolen; if detected on Amazon, report...&lt;br&gt;
        &lt;/span&gt;

    &lt;/div&gt;

    &lt;/body&gt;
 &lt;/html&gt;
</code></pre>

<p>On the live website, your browser reads the <code>&lt;style&gt;</code> tag in the <code>&lt;head&gt;</code> and knows to hide the spam <code>&lt;span&gt;</code>. You never see it.</p>

<h3 id="what-freshrss-sees-the-problem">What FreshRSS Sees (The Problem)</h3>

<p>I’ve told FreshRSS to only grab the content from <code>.chapter-content</code> which is the actual content of a post. So, FreshRSS requests the page and then scrapes only this part:</p>

<pre><code class="language-html">
&lt;p class=&#34;cnMxYzY0ZjllNmVj...&#34;&gt;
    &lt;span style=&#34;font-weight: 400&#34;&gt;Nathan got the message...&lt;/span&gt;
&lt;/p&gt;

&lt;p class=&#34;cnNiYTMwZmE4YjE2...&#34;&gt; &lt;/p&gt;

&lt;p class=&#34;cnNiOWQ0MDU1MDA2...&#34;&gt;
    &lt;span style=&#34;font-weight: 400&#34;&gt;Sarya waved her hand...&lt;/span&gt;
&lt;/p&gt;

&lt;p class=&#34;cnM0NjAwNWU4Y2Vl...&#34;&gt; &lt;/p&gt;

&lt;span class=&#34;cjZhYjNmYjZkZmFjZTQ2YTk4OWQwYjRiMjRjZDQyOGRl&#34;&gt;
    &lt;br&gt;The narrative has been stolen; if detected on Amazon, report...&lt;br&gt;
&lt;/span&gt;
</code></pre>

<p>Since FreshRSS never saw the <code>&lt;head&gt;</code> or the <code>&lt;style&gt;</code> tag, it has no idea it’s supposed to hide the spam <code>&lt;span&gt;</code>. It just displays all the text it found, resulting in this output in your feed reader:</p>

<pre><code>Nathan got the message...

Sarya waved her hand...

The narrative has been stolen; if detected on Amazon, report...

</code></pre>

<p>This is the core of the issue: the content is hidden by a CSS rule that FreshRSS isn’t loading, and the class names are random, so you can’t just block the class.</p>

<h3 id="the-fix-css-selectors">The Fix: CSS Selectors</h3>

<p>You need to tell FreshRSS how to remove the unwanted elements based on their structure, not their random class names.</p>

<p>Go to: <strong>Advanced</strong> –&gt; <strong>CSS selector of the elements to remove</strong>.
Paste this in the box:</p>

<pre><code class="language-css">.chapter-content &gt; span
</code></pre>

<p>This selector targets any <code>&lt;span&gt;</code> element that is a direct child (using <code>&gt;</code>) of <code>.chapter-content</code>.</p>

<p>The spam text <code>&lt;span class=&#34;cjZhY...&#34;&gt;...&lt;/span&gt;</code> matches this rule.</p>

<p>The actual story text <code>&lt;span style=&#34;font-weight: 400&#34;&gt;...&lt;/span&gt;</code> is safe because it’s a “grandchild” (it’s inside a <code>&lt;p&gt;</code> tag), not a direct child.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/bypassing-royalroad</guid>
      <pubDate>Wed, 20 Nov 2024 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>RosterHash: fantasy football schedule viewer</title>
      <link>https://edfig.dev/eddie/rosterhash-fantasy-football-schedule-viewer</link>
      <description>&lt;![CDATA[I joined another league this year.&#xA;&#xA;I was losing track of who played when and what league.&#xA;&#xA;So I made GameTime (nope, that’s taken) RosterHash!&#xA;&#xA;Screenshot20251120150110&#xA;&#xA;Enter your Sleeper username and away you go.&#xA;&#xA;Features:&#xA;Can save up to 4 favorite teams for checking when they play and the score&#xA;Shows your players per league per game and color codes it all.&#xA;Completed games auto-collapse and get out of the way&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<p>I joined another league this year.</p>

<p>I was losing track of who played when and what league.</p>

<p>So I made <del>GameTime (nope, that’s taken)</del> <a href="https://rosterhash.edfig.dev" rel="nofollow">RosterHash</a>!</p>

<p><img src="https://bear-images.sfo2.cdn.digitaloceanspaces.com/edfig/screenshot_20251120_150110.webp" alt="Screenshot_20251120_150110"></p>

<p>Enter your Sleeper username and away you go.</p>

<p>Features:
– Can save up to 4 favorite teams for checking when they play and the score
– Shows your players per league per game and color codes it all.
– Completed games auto-collapse and get out of the way</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/rosterhash-fantasy-football-schedule-viewer</guid>
      <pubDate>Wed, 20 Nov 2024 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>Custom Domain and Emails</title>
      <link>https://edfig.dev/eddie/custom-domain-and-emails</link>
      <description>&lt;![CDATA[What is this?&#xA;&#xA;Let’s say you wanted to buy a domain like edfig.dev. You can host a personal blog at this address. Once you buy the domain, not only can you host content, but with a bit more tinkering you can send and receive emails with it.&#xA;&#xA;You can email eddie@edfig.dev or admin@edfig.dev and that email will make its way to my inbox. You can set up rules to handle specific addresses too.&#xA;&#xA;You’ll need to create accounts for the following:&#xA;Mailgun.com&#xA;porkbun.com&#xA;&#xA;Setting it up&#xA;&#xA;1. The Domain&#xA;&#xA;You can buy a domain from any registrar, I recommend PorkBun or Cloudflare. I’ll be using Porkbun for this discussion.&#xA;&#xA;Pricing will depend on the name and what TLD (the .com part). I occasionally run into issues with sites not recognizing eddie@fig.systems as a valid email address because it’s a lesser known domain.&#xA;&#xA;Once you have it you can enter DNS records to where you host stuff or start using it for email.&#xA;&#xA;2. The Email&#xA;&#xA;Email is one of those things you shouldn’t host yourself, it’s very annoying. But luckily there are services out there that take care of most of the hassle. MailGun and SendGrid are two such services. I’ll be using Mailgun here.&#xA;&#xA;With Mailgun I can:&#xA;Receive emails at custom email addresses with my domain&#xA;Route those emails based on rules&#xA; e.g. Emails sent to no-reply@edfig.dev are completely dropped&#xA;Send emails AS those email addresses through gmail&#xA; Receive an email at admin@edfig.dev at my regular gmail account and reply as admin@fig.systems&#xA;Use their API to programmatically send emails&#xA;Use their SMTP servers to send as custom email addresses&#xA; My self hosted services send notification emails as no-reply@fig.systems or as service_name@fig.systems&#xA;&#xA;3. Setting up DNS&#xA;Buy a domain at porkbun.&#xA;&#xA;Pick your favorite. I’ll be using figgy.foo for this, there was a good deal on it.&#xA;Log into Mailgun&#xA;Go to Send -  Sending -  Domains&#xA;Click on “Add New Domain”&#xA;Add figgy.foo, leave the rest blank, click Add Domain&#xA;Add DNS records to porkbun.&#xA;&#xA;You’ll be provided with records for sending, receiving, and tracking.&#xA;&#xA;In Porkbun Domain Management select DNS when you hover over your new domain.&#xA;&#xA;Copy the entries over. Make sure the Types match and that you leave off the figgy.foo portion in the host field in porkbun. Anything you add in the host field will automatically append your domain to the end of it. If the field is just figgy.foo then leave the host field blank.&#xA;&#xA;Copy all the Value fields from Mailgun to the Answer field in Porkbun and then click on Verify at the top right. You should see the status change to Active.&#xA;&#xA;This is what your records in porkbun should look like.&#xA;&#xA;porkbun-email-dns-records&#xA;&#xA;4. Setting up Mailgun&#xA;&#xA;Routing emails.&#xA;Go to Send -  Receiving and Create a Route.&#xA;Expression Type -  Match Recipient&#xA; Enter admin@figgy.foo&#xA;Enable Forward and fill in your personal address. For me that’d be my normal gmail address.&#xA;Set priority to 50 so you have space to add future routes before or after this route.&#xA;Add a simple description like “send to gmail” and Create the Route.&#xA;&#xA;At the free tier you can only have 5 routes total. I only use the following:&#xA;Match no-reply@figgy.foo, Store and Notify and Stop processing.&#xA;Match family@figgy.foo, forward that email to multiple family members.&#xA; Useful for events and family plans.&#xA;Match Kindle@figgy.foo, forward to my custom Amazon provided kindle email address for sending epubs/pdfs.&#xA; much friendlier address than what they make for you.&#xA;A catch all final route that just forwards to my personal address.&#xA;&#xA;Number 4 is where most of the magic and utility of setting all this up happens. I can give out unlimited custom email addresses and I’ll know who sent them by the address. That is, if I give out businessName@fig.systems I can later use that in gmail to filter, block, or search for anything related to that business. I can even see who sold my info if I start getting spam from that address.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<h1 id="what-is-this">What is this?</h1>

<p>Let’s say you wanted to buy a domain like <code>edfig.dev</code>. You can host a personal blog at this address. Once you buy the domain, not only can you host content, but with a bit more tinkering you can send and receive emails with it.</p>

<p>You can email <code>eddie@edfig.dev</code> or <code>admin@edfig.dev</code> and that email will make its way to my inbox. You can set up rules to handle specific addresses too.</p>

<p>You’ll need to create accounts for the following:
– Mailgun.com
– porkbun.com</p>

<h1 id="setting-it-up">Setting it up</h1>

<h2 id="1-the-domain">1. The Domain</h2>

<p>You can buy a domain from any registrar, I recommend <a href="https://porkbun.com/" rel="nofollow">PorkBun</a> or <a href="https://www.cloudflare.com/products/registrar/" rel="nofollow">Cloudflare</a>. I’ll be using Porkbun for this discussion.</p>

<p>Pricing will depend on the name and what TLD (the <code>.com</code> part). I occasionally run into issues with sites not recognizing <code>eddie@fig.systems</code> as a valid email address because it’s a lesser known domain.</p>

<p>Once you have it you can enter DNS records to where you host stuff or start using it for email.</p>

<h2 id="2-the-email">2. The Email</h2>

<p>Email is one of those things you shouldn’t host yourself, it’s very annoying. But luckily there are services out there that take care of most of the hassle. <a href="https://www.mailgun.com/" rel="nofollow">MailGun</a> and <a href="https://sendgrid.com/en-us" rel="nofollow">SendGrid</a> are two such services. I’ll be using Mailgun here.</p>

<p>With Mailgun I can:
– Receive emails at custom email addresses with my domain
– Route those emails based on rules
 – e.g. Emails sent to <code>no-reply@edfig.dev</code> are completely dropped
– Send emails AS those email addresses through gmail
 – Receive an email at <code>admin@edfig.dev</code> at my regular gmail account and reply as <code>admin@fig.systems</code>
– Use their API to programmatically send emails
– Use their SMTP servers to send as custom email addresses
 – My self hosted services send notification emails as <code>no-reply@fig.systems</code> or as <code>service_name@fig.systems</code></p>

<h2 id="3-setting-up-dns">3. Setting up DNS</h2>
<ul><li>Buy a domain at porkbun.</li></ul>

<p>Pick your favorite. I’ll be using <code>figgy.foo</code> for this, there was a good deal on it.
– Log into Mailgun
– Go to Send –&gt; Sending –&gt; Domains
– Click on “Add New Domain”
– Add <code>figgy.foo</code>, leave the rest blank, click Add Domain
– Add DNS records to porkbun.</p>

<p>You’ll be provided with records for sending, receiving, and tracking.</p>

<p>In Porkbun Domain Management select <code>DNS</code> when you hover over your new domain.</p>

<p>Copy the entries over. Make sure the Types match and that you leave off the <code>figgy.foo</code> portion in the <code>host</code> field in porkbun. Anything you add in the host field will automatically append your domain to the end of it. If the field is just <code>figgy.foo</code> then leave the host field blank.</p>

<p>Copy all the Value fields from Mailgun to the Answer field in Porkbun and then click on Verify at the top right. You should see the status change to Active.</p>

<p>This is what your records in porkbun should look like.</p>

<p><img src="/images/porkbunemailrecords.png" alt="porkbun-email-dns-records"></p>

<h2 id="4-setting-up-mailgun">4. Setting up Mailgun</h2>

<h3 id="routing-emails">Routing emails.</h3>
<ul><li></li></ul>

<p>Go to Send –&gt; Receiving and Create a Route.
-</p>

<p>Expression Type –&gt; Match Recipient
 – Enter <code>admin@figgy.foo</code>
-</p>

<p>Enable Forward and fill in your personal address. For me that’d be my normal gmail address.
-</p>

<p>Set priority to 50 so you have space to add future routes before or after this route.
-</p>

<p>Add a simple description like “send to gmail” and Create the Route.</p>

<p>At the free tier you can only have 5 routes total. I only use the following:
– Match <code>no-reply@figgy.foo</code>, Store and Notify and Stop processing.
– Match <code>family@figgy.foo</code>, forward that email to multiple family members.
 – Useful for events and family plans.
– Match <code>Kindle@figgy.foo</code>, forward to my custom <a href="https://www.amazon.com/sendtokindle/email" rel="nofollow">Amazon provided</a> kindle email address for sending epubs/pdfs.
 – much friendlier address than what they make for you.
– A catch all final route that just forwards to my personal address.</p>

<p>Number 4 is where most of the magic and utility of setting all this up happens. I can give out unlimited custom email addresses and I’ll know who sent them by the address. That is, if I give out <code>businessName@fig.systems</code> I can later use that in gmail to filter, block, or search for anything related to that business. I can even see who sold my info if I start getting spam from that address.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/custom-domain-and-emails</guid>
      <pubDate>Mon, 07 Oct 2024 00:00:00 +0000</pubDate>
    </item>
    <item>
      <title>RSS - Still Alive</title>
      <link>https://edfig.dev/eddie/rss-still-alive</link>
      <description>&lt;![CDATA[RSS - Still Very Useful&#xA;&#xA;I like having a centralized curated list of content. I’d rather go to a single page to catch up on new content instead of visiting or remembering to visit a bunch of different sites. I also don’t like having to deal with cookies and sites tracking my every move.&#xA;&#xA;I use: FreshRSS, RSSHub, and RSSHub-Radar&#xA;&#xA;I used to only use RSS for blogs and other text based content but with the above tools I can RSS-ify most anything.&#xA;&#xA;The Flow of Content&#xA;&#xA;FreshRSS is the rss aggregator and can be used as the reader either on desktop or as a PWA on mobile. I host my own at feeds.fig.systems. It’s got a few slick themes and has options to scrape webpages with x-paths. You provide a URL and use elements to select what you’d like to create your feed from, that’s a lot of work per feed.&#xA;&#xA;That was my first go at RSS-ifying everything until I learned about RSSHub which does the same thing but handles it automatically. I host my own instance at RSSHub.fig.systems. They provide pre-made “routes” which make turning many common content sources into feeds.&#xA;&#xA;For example I could add the feed rsshub.fig.systems/youtube/user/linustechtips/ to feeds.fig.systems and I’d get a new entry every time that channel uploads a new video.&#xA;&#xA;Having to look up the routes can be annoying. Enter RSSHub-Radar, a nice browser extension that can automatically detect and provide the route for a given page you’d like to rss-ify. The extension can also be configured to format the url for whatever rss aggregator you use, FreshRSS or otherwise.&#xA;&#xA;It’s worth going over RSSHub’s routes to get an idea of what can be turned into an rss feed.&#xA;&#xA;| Eddie]]&gt;</description>
      <content:encoded><![CDATA[<h1 id="rss-still-very-useful">RSS – Still Very Useful</h1>

<p>I like having a centralized curated list of content. I’d rather go to a single page to catch up on new content instead of visiting or remembering to visit a bunch of different sites. I also don’t like having to deal with cookies and sites tracking my every move.</p>

<p>I use: <a href="https://freshrss.org/index.html" rel="nofollow">FreshRSS</a>, <a href="https://docs.rsshub.app/" rel="nofollow">RSSHub</a>, and <a href="https://github.com/DIYgod/RSSHub-Radar" rel="nofollow">RSSHub-Radar</a></p>

<p>I used to only use RSS for blogs and other text based content but with the above tools I can RSS-ify most anything.</p>

<h2 id="the-flow-of-content">The Flow of Content</h2>

<p><strong>FreshRSS</strong> is the rss aggregator and can be used as the reader either on desktop or as a PWA on mobile. I host my own at <a href="https://feeds.fig.systems" rel="nofollow">feeds.fig.systems</a>. It’s got a few slick themes and has options to <a href="https://danq.me/2022/09/27/freshrss-xpath/" rel="nofollow">scrape webpages with x-paths</a>. You provide a URL and use elements to select what you’d like to create your feed from, that’s a lot of work per feed.</p>

<p>That was my first go at RSS-ifying everything until I learned about <strong>RSSHub</strong> which does the same thing but handles it automatically. I host my own instance at RSSHub.fig.systems. They provide pre-made “routes” which make turning many common content sources into feeds.</p>

<p>For example I could add the feed <code>rsshub.fig.systems/youtube/user/linustechtips/</code> to feeds.fig.systems and I’d get a new entry every time that channel uploads a new video.</p>

<p>Having to look up the routes can be annoying. Enter <strong>RSSHub-Radar</strong>, a nice browser extension that can automatically detect and provide the route for a given page you’d like to rss-ify. The extension can also be configured to format the url for whatever rss aggregator you use, FreshRSS or otherwise.</p>

<p>It’s worth going over <a href="https://docs.rsshub.app/routes/popular" rel="nofollow">RSSHub’s routes</a> to get an idea of what can be turned into an rss feed.</p>

<p>| Eddie</p>
]]></content:encoded>
      <guid>https://edfig.dev/eddie/rss-still-alive</guid>
      <pubDate>Sat, 05 Oct 2024 00:00:00 +0000</pubDate>
    </item>
  </channel>
</rss>