<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom"><title>Tinker, break and fix</title><link href="/" rel="alternate"></link><link href="all.atom.xml" rel="self"></link><id>/</id><updated>2024-01-21T01:45:00+00:00</updated><entry><title>RHCSA 9 changes</title><link href="2024-01-21-rhcsa-changes.html" rel="alternate"></link><published>2024-01-21T01:45:00+00:00</published><updated>2024-01-21T01:45:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2024-01-21:2024-01-21-rhcsa-changes.html</id><summary type="html">&lt;p&gt;For anyone else labbing with Rhel 9.3 and messing with /etc/default/grub GRUB_CMDLINE_LINUX= options not taking effect,
such as removing options "rhgb quiet",
after running grub2-mkconfig,
you now need to add --update-bls-cmdline to grub2-mkconfig or
set GRUB_ENABLE_BLSCFG=true to GRUB_ENABLE_BLSCFG=false.&lt;/p&gt;
&lt;p&gt;https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux …&lt;/p&gt;</summary><content type="html">&lt;p&gt;For anyone else labbing with Rhel 9.3 and messing with /etc/default/grub GRUB_CMDLINE_LINUX= options not taking effect,
such as removing options "rhgb quiet",
after running grub2-mkconfig,
you now need to add --update-bls-cmdline to grub2-mkconfig or
set GRUB_ENABLE_BLSCFG=true to GRUB_ENABLE_BLSCFG=false.&lt;/p&gt;
&lt;p&gt;https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/9.3_release_notes/index&lt;/p&gt;
&lt;p&gt;section 4.9 boot loader&lt;/p&gt;
&lt;p&gt;Alternatively, we can use grubby, such as:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# grubby --update-kernel=ALL --args=&amp;quot;bogus_kernel_arg&amp;quot;&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# grubby --info /boot/vmlinuz-5.14.0-362.8.1.el9_3.x86_64&lt;/span&gt;
&lt;span class="nv"&gt;index&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="nv"&gt;kernel&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/boot/vmlinuz-5.14.0-362.8.1.el9_3.x86_64&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;args&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;ro resume=/dev/mapper/rhel-swap rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap bogus_kernel_arg&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;root&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/dev/mapper/rhel-root&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;initrd&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/boot/initramfs-5.14.0-362.8.1.el9_3.x86_64.img &lt;/span&gt;&lt;span class="nv"&gt;$tuned_initrd&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;Red Hat Enterprise Linux (5.14.0-362.8.1.el9_3.x86_64) 9.3 (Plow)&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;id&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;98edf952bc814fc39e39cb067e0381e8-5.14.0-362.8.1.el9_3.x86_64&amp;quot;&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# grubby --update-kernel=ALL --remove-args=&amp;quot;bogus_kernel_arg&amp;quot; /boot/vmlinuz-5.14.0-362.8.1.el9_3.x86_64&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# grubby --info /boot/vmlinuz-5.14.0-362.8.1.el9_3.x86_64&lt;/span&gt;
&lt;span class="nv"&gt;index&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="nv"&gt;kernel&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/boot/vmlinuz-5.14.0-362.8.1.el9_3.x86_64&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;args&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;ro resume=/dev/mapper/rhel-swap rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;root&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/dev/mapper/rhel-root&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;initrd&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;/boot/initramfs-5.14.0-362.8.1.el9_3.x86_64.img &lt;/span&gt;&lt;span class="nv"&gt;$tuned_initrd&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;Red Hat Enterprise Linux (5.14.0-362.8.1.el9_3.x86_64) 9.3 (Plow)&amp;quot;&lt;/span&gt;
&lt;span class="nv"&gt;id&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;98edf952bc814fc39e39cb067e0381e8-5.14.0-362.8.1.el9_3.x86_64&amp;quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</content><category term="posts"></category></entry><entry><title>RHEL 9 hidden grub menu</title><link href="2024-01-21-rhcsa-hidden-grub-menu.html" rel="alternate"></link><published>2024-01-21T01:45:00+00:00</published><updated>2024-01-21T01:45:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2024-01-21:2024-01-21-rhcsa-hidden-grub-menu.html</id><summary type="html">&lt;p&gt;For anyone taking RHCSA9 exam soon, this might be helpful.&lt;/p&gt;
&lt;p&gt;On newly installed Rhel9.3 virtual machines, the grub2 boot menu
gets hidden after successful boots.&lt;/p&gt;
&lt;p&gt;This makes test exam tasks more difficult that wants you to
reset root passwords, by going to emergency mode and remounting
/sysroot rw.&lt;/p&gt;
&lt;p&gt;This …&lt;/p&gt;</summary><content type="html">&lt;p&gt;For anyone taking RHCSA9 exam soon, this might be helpful.&lt;/p&gt;
&lt;p&gt;On newly installed Rhel9.3 virtual machines, the grub2 boot menu
gets hidden after successful boots.&lt;/p&gt;
&lt;p&gt;This makes test exam tasks more difficult that wants you to
reset root passwords, by going to emergency mode and remounting
/sysroot rw.&lt;/p&gt;
&lt;p&gt;This can be undone by unsetting the menu_auto_hide grub2
option with grub2-editenv, such as:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;user@hostname&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;$&lt;span class="w"&gt; &lt;/span&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;grub2-editenv&lt;span class="w"&gt; &lt;/span&gt;list
&lt;span class="nv"&gt;saved_entry&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;841c0cb68442436a89b4246c45e8c3a0-5.14.0-362.8.1.el9_3.x86_64
&lt;span class="nv"&gt;menu_auto_hide&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;
&lt;span class="nv"&gt;boot_success&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="nv"&gt;boot_indeterminate&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;user@hostname&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;$&lt;span class="w"&gt; &lt;/span&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;grub2-editenv&lt;span class="w"&gt; &lt;/span&gt;-&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;unset&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;menu_auto_hide
&lt;span class="o"&gt;[&lt;/span&gt;user@hostname&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;$&lt;span class="w"&gt; &lt;/span&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;grub2-editenv&lt;span class="w"&gt; &lt;/span&gt;list
&lt;span class="nv"&gt;saved_entry&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;841c0cb68442436a89b4246c45e8c3a0-5.14.0-362.8.1.el9_3.x86_64
&lt;span class="nv"&gt;boot_success&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="nv"&gt;boot_indeterminate&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</content><category term="posts"></category></entry><entry><title>Ansible RSS feeds</title><link href="2023-12-05-post.html" rel="alternate"></link><published>2023-12-05T04:45:00+00:00</published><updated>2023-12-05T04:45:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2023-12-05:2023-12-05-post.html</id><summary type="html">&lt;p&gt;I've looked for an rss feed link for the Ansible Community release
(not ansible-core)
that I usually install with pip, but could never find.&lt;/p&gt;
&lt;p&gt;I should have looked on pypi.org first, from &lt;a href="https://pypi.org/project/ansible"&gt;https://pypi.org/project/ansible&lt;/a&gt;
you can find Release history tab, which gives this link that can …&lt;/p&gt;</summary><content type="html">&lt;p&gt;I've looked for an rss feed link for the Ansible Community release
(not ansible-core)
that I usually install with pip, but could never find.&lt;/p&gt;
&lt;p&gt;I should have looked on pypi.org first, from &lt;a href="https://pypi.org/project/ansible"&gt;https://pypi.org/project/ansible&lt;/a&gt;
you can find Release history tab, which gives this link that can be subscribed to:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://pypi.org/rss/project/ansible/releases.xml"&gt;https://pypi.org/rss/project/ansible/releases.xml&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;For ansible-core, visit either &lt;a href="https://pypi.org/project/ansible-core/#history"&gt;https://pypi.org/project/ansible-core/#history&lt;/a&gt;
(the rss link being &lt;a href="https://pypi.org/rss/project/ansible-core/releases.xml"&gt;https://pypi.org/rss/project/ansible-core/releases.xml&lt;/a&gt;) or
find &lt;a href="https://github.com/ansible/ansible/releases.atom"&gt;https://github.com/ansible/ansible/releases.atom&lt;/a&gt; from &lt;a href="https://github.com/ansible/ansible/releases"&gt;https://github.com/ansible/ansible/releases&lt;/a&gt;.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>SMR drives suck</title><link href="2023-03-18-smr.html" rel="alternate"></link><published>2023-03-18T14:45:00+00:00</published><updated>2023-03-18T14:45:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2023-03-18:2023-03-18-smr.html</id><content type="html">&lt;p&gt;Never again will I buy any SMR hdds.&lt;/p&gt;
&lt;p&gt;I cheaped out on 2 drives years ago and I've been
regretting it ever since.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Weekend</title><link href="2023-03-18-weekend.html" rel="alternate"></link><published>2023-03-18T04:45:00+00:00</published><updated>2023-03-18T04:45:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2023-03-18:2023-03-18-weekend.html</id><content type="html">&lt;p&gt;Project 1 for the weekend:&lt;/p&gt;
&lt;p&gt;replace shorthand image references in my
ansible/docker-compose playbooks from eg:&lt;/p&gt;
&lt;p&gt;'traefik:2.9'&lt;/p&gt;
&lt;p&gt;to&lt;/p&gt;
&lt;p&gt;'docker.io/library/traefik:2.9'&lt;/p&gt;
&lt;p&gt;I also need to change them in my Dockerfiles, yay.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>They took our jobs! .. err Dilbert comics</title><link href="2023-03-14-dilbert.html" rel="alternate"></link><published>2023-03-14T09:21:00+00:00</published><updated>2023-03-14T09:21:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2023-03-14:2023-03-14-dilbert.html</id><summary type="html">&lt;p&gt;Dilbert.com now redirects to https://linktr.ee/scottadams, making
my Dilbert comic scraper useless.&lt;/p&gt;
&lt;p&gt;The scraper collected a total of 12382 comics over the past 6-7 years
I was working on it. I had to save the last 2 available comics from
&lt;a href="https://web.archive.org/web/20230000000000*/https://dilbert.com/"&gt;archive.org&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;So the collection has a …&lt;/p&gt;</summary><content type="html">&lt;p&gt;Dilbert.com now redirects to https://linktr.ee/scottadams, making
my Dilbert comic scraper useless.&lt;/p&gt;
&lt;p&gt;The scraper collected a total of 12382 comics over the past 6-7 years
I was working on it. I had to save the last 2 available comics from
&lt;a href="https://web.archive.org/web/20230000000000*/https://dilbert.com/"&gt;archive.org&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;So the collection has a grand total of 12384 comics,
measuring 1490224578 bytes(1.4GiB),
starting from the first one from 1989-04-16,
to the last one from 2023-03-12.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>PAM_FAILLOCK</title><link href="2023-03-12-pam-faillock.html" rel="alternate"></link><published>2023-03-12T14:21:00+00:00</published><updated>2023-03-12T14:21:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2023-03-12:2023-03-12-pam-faillock.html</id><summary type="html">&lt;p&gt;In the Sander Van Vugt RHCSA video rcsa_01_06_08.mp4 video(L6: Managing Users and Groups/Managing Password Properties),
he mentions looking into the pam_tally2 module.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://access.redhat.com/solutions/62949"&gt;What is pam_faillock and how to use it in Red Hat Enterprise Linux?&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The kb above says pam_tally2 has been replaced with pam_faillock.&lt;/p&gt;
&lt;p&gt;Its man …&lt;/p&gt;</summary><content type="html">&lt;p&gt;In the Sander Van Vugt RHCSA video rcsa_01_06_08.mp4 video(L6: Managing Users and Groups/Managing Password Properties),
he mentions looking into the pam_tally2 module.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://access.redhat.com/solutions/62949"&gt;What is pam_faillock and how to use it in Red Hat Enterprise Linux?&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The kb above says pam_tally2 has been replaced with pam_faillock.&lt;/p&gt;
&lt;p&gt;Its man page can be seen at:&lt;/p&gt;
&lt;p&gt;man pam_faillock&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Finding a Repo's Github Release RSS link</title><link href="2022-09-01-github-releases-rss.html" rel="alternate"></link><published>2022-09-01T19:21:00+01:00</published><updated>2022-09-01T19:21:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-09-01:2022-09-01-github-releases-rss.html</id><summary type="html">&lt;p&gt;I've been following a few projects' releases over RSS
to determine see new releases and when to upgrade docker
images I use locally.&lt;/p&gt;
&lt;p&gt;For some software, it's not worth it to upgrade straightaway to
a new release(eg on a new v13.0 release). I like to
see if there …&lt;/p&gt;</summary><content type="html">&lt;p&gt;I've been following a few projects' releases over RSS
to determine see new releases and when to upgrade docker
images I use locally.&lt;/p&gt;
&lt;p&gt;For some software, it's not worth it to upgrade straightaway to
a new release(eg on a new v13.0 release). I like to
see if there are any new bugfix releases afterwards in the coming
days or weeks.&lt;/p&gt;
&lt;p&gt;On Github.com, a project/repo's releases RSS link follows this format:&lt;/p&gt;
&lt;p&gt;https://github.com/{username,orgname}/reponame/releases.atom&lt;/p&gt;
&lt;p&gt;Rss for tag feeds are at:&lt;/p&gt;
&lt;p&gt;https://github.com/{username,orgname}/reponame/tags.atom&lt;/p&gt;
&lt;p&gt;I know for Docker you can/could use &lt;a href="https://github.com/containrrr/watchtower"&gt;Watchtower&lt;/a&gt; to upgrade your software
or send notifications when upgrades are available. I should look into watchtower anyway and its &lt;a href="https://containrrr.dev/watchtower/notifications/"&gt;email notifications&lt;/a&gt; .&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>2022-08-08 Keep an eye on Gitlab storage</title><link href="2022-08-08-gitlab-storage.html" rel="alternate"></link><published>2022-08-08T22:15:00+01:00</published><updated>2022-08-08T22:15:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-08-08:2022-08-08-gitlab-storage.html</id><content type="html">&lt;p&gt;As someone who uses Gitlab CI a lot, I ought to take a look at the following link soon.&lt;/p&gt;
&lt;p&gt;https://docs.gitlab.com/ee/user/usage_quotas.html#namespace-storage-limit-enforcement-schedule&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>2022-08-08 Updating my docker images to multiarch builds</title><link href="2022-08-08-docker.html" rel="alternate"></link><published>2022-08-08T22:00:00+01:00</published><updated>2022-08-08T22:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-08-08:2022-08-08-docker.html</id><summary type="html">&lt;p&gt;I've been updating my dockerfiles on my several git
repos across Gitlab and Github.&lt;/p&gt;
&lt;p&gt;Some of them have working images now for
armv7(32 bit arm), armv8(64 bit arm) and amd64(most desktops these days).&lt;/p&gt;
&lt;p&gt;I only use armv7 and amd64 images for my raspberry pies and my pc-s …&lt;/p&gt;</summary><content type="html">&lt;p&gt;I've been updating my dockerfiles on my several git
repos across Gitlab and Github.&lt;/p&gt;
&lt;p&gt;Some of them have working images now for
armv7(32 bit arm), armv8(64 bit arm) and amd64(most desktops these days).&lt;/p&gt;
&lt;p&gt;I only use armv7 and amd64 images for my raspberry pies and my pc-s.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>2022-05-10 Change of email service provider</title><link href="2022-05-10-email.html" rel="alternate"></link><published>2022-05-10T22:00:00+01:00</published><updated>2022-05-10T22:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-05-10:2022-05-10-email.html</id><summary type="html">&lt;p&gt;I've changed my email service provider to Migadu from
Google Gsuite.&lt;/p&gt;
&lt;p&gt;After 2 years, I've found I paid too much for email hosting.&lt;/p&gt;
&lt;p&gt;I also used storage provided by gsuite for backup purposes,
fortunately never needed to use it.&lt;/p&gt;
&lt;p&gt;Migration of my emails was easy.&lt;/p&gt;
&lt;p&gt;Changed over DNS settings with …&lt;/p&gt;</summary><content type="html">&lt;p&gt;I've changed my email service provider to Migadu from
Google Gsuite.&lt;/p&gt;
&lt;p&gt;After 2 years, I've found I paid too much for email hosting.&lt;/p&gt;
&lt;p&gt;I also used storage provided by gsuite for backup purposes,
fortunately never needed to use it.&lt;/p&gt;
&lt;p&gt;Migration of my emails was easy.&lt;/p&gt;
&lt;p&gt;Changed over DNS settings with terraform.&lt;/p&gt;
&lt;p&gt;Job done.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>2022-04-13</title><link href="2022-04-13.html" rel="alternate"></link><published>2022-04-13T00:00:00+01:00</published><updated>2022-04-13T00:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-04-13:2022-04-13.html</id><summary type="html">&lt;h1&gt;New services to add&lt;/h1&gt;
&lt;p&gt;Yay, more things to keep track of!&lt;/p&gt;
&lt;h2&gt;Note taking&lt;/h2&gt;
&lt;p&gt;Right now my note taking for personal stuff
is a mess between vscode md files, local files
and some files on my phone.&lt;/p&gt;
&lt;p&gt;Also something to sync them? Syncthing or just
some service like onenote or evernote …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;New services to add&lt;/h1&gt;
&lt;p&gt;Yay, more things to keep track of!&lt;/p&gt;
&lt;h2&gt;Note taking&lt;/h2&gt;
&lt;p&gt;Right now my note taking for personal stuff
is a mess between vscode md files, local files
and some files on my phone.&lt;/p&gt;
&lt;p&gt;Also something to sync them? Syncthing or just
some service like onenote or evernote?&lt;/p&gt;
&lt;h2&gt;Local monitoring&lt;/h2&gt;
&lt;p&gt;I have no local monitoring services used,
as I didn't feel them necessary for a desktop
and a laptop.&lt;/p&gt;
&lt;p&gt;I need something lightweight than runs on a pi 2 or 3.&lt;/p&gt;
&lt;h2&gt;Web page change monitor&lt;/h2&gt;
&lt;p&gt;Some service that watches for changes in web pages.&lt;/p&gt;
&lt;p&gt;Something that notify me if it detects changes in search results
on that page, instead of just straight html changes(which would
be pointless).&lt;/p&gt;
&lt;p&gt;Some projects to consider here are:&lt;/p&gt;
&lt;p&gt;https://github.com/PipedreamHQ/pipedream&lt;/p&gt;
&lt;p&gt;https://github.com/huginn/huginn&lt;/p&gt;
&lt;p&gt;https://github.com/home-assistant&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>2022-04-12</title><link href="2022-04-12.html" rel="alternate"></link><published>2022-04-12T12:00:00+01:00</published><updated>2022-04-12T12:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2022-04-12:2022-04-12.html</id><content type="html">&lt;h1&gt;Just wonderful&lt;/h1&gt;
&lt;p&gt;Things are just great in 2022 so far
in the UK, aren't they?&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>droneci-https</title><link href="droneci-https.html" rel="alternate"></link><published>2021-05-29T12:00:00+01:00</published><updated>2021-05-29T12:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2021-05-29:droneci-https.html</id><summary type="html">&lt;h1&gt;Droneci and SSL&lt;/h1&gt;
&lt;p&gt;Finally managed to get Drone working properly
with traefik v2 in docker.&lt;/p&gt;
&lt;p&gt;I had to go back and forth while I managed to track
down my issues, which were:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;wrong hostname configured on the drone docker
label parts&lt;/li&gt;
&lt;li&gt;play with docker env vars while I get the …&lt;/li&gt;&lt;/ul&gt;</summary><content type="html">&lt;h1&gt;Droneci and SSL&lt;/h1&gt;
&lt;p&gt;Finally managed to get Drone working properly
with traefik v2 in docker.&lt;/p&gt;
&lt;p&gt;I had to go back and forth while I managed to track
down my issues, which were:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;wrong hostname configured on the drone docker
label parts&lt;/li&gt;
&lt;li&gt;play with docker env vars while I get the
oath2 redirect working between gitea,
drone and traefik&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;SSL and redirection required me to change up config somewhat,
which looks like this below:&lt;/p&gt;
&lt;p&gt;note: it's from an ansible playbook&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;Run drone docker-compose&lt;/span&gt;
&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nt"&gt;docker_compose&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;project_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;droneci&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;state&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;present&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;pull&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;yes&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;remove_orphans&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;yes&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;remove_volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;yes&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;restarted&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;yes&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;remove_images&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;all&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;debug&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;true&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;definition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="nt"&gt;version&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;#39;2&amp;#39;&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="nt"&gt;networks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;ci&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;          &lt;/span&gt;&lt;span class="nt"&gt;external&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;true&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="nt"&gt;services&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;

&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;drone&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;container_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drone&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drone/drone:1&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;restart&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;unless-stopped&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;hostname&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drone&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;networks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;ci&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;environment&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_GITEA_SERVER={{ DRONE_GITEA_SERVER }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_GITEA_CLIENT_ID={{ DRONE_GITEA_CLIENT_ID }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_GITEA_CLIENT_SECRET={{ GITEA_CLIENT_SECRET }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_RPC_SECRET={{ DRONE_RPC_SECRET }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_SERVER_HOST={{ DRONE_SERVER_HOST }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_SERVER_PROTO=https&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_DATADOG_ENABLED=false&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;labels&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;traefik.enable=true&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;traefik.http.routers.drone.rule=Host(`drone.sub.domain.tld`)&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;traefik.http.routers.drone.entrypoints=websecure&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;traefik.http.routers.drone.tls.certresolver=myresolver&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/lib/drone:/data&lt;/span&gt;

&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;drunner&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;container_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drunner&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drone/drone-runner-docker:1&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;restart&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;unless-stopped&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;hostname&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;drunner&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;ports&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;3000:3000&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;networks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;ci&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;environment&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_RPC_PROTO=https&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_RPC_HOST=drone&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_RPC_SECRET={{ DRONE_RPC_SECRET }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_SERVER_HOST=drone&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_RUNNER_CAPACITY=2&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;DRONE_DATADOG_ENABLED=false&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/run/docker.sock:/var/run/docker.sock&lt;/span&gt;

&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;traefik&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;traefik:2.2&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;restart&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;unless-stopped&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;container_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;traefik&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;command&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--providers.docker=true&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--providers.docker.exposedbydefault=false&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--entrypoints.web.address=:80&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--entrypoints.websecure.address=:443&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--entrypoints.web.http.redirections.entrypoint.to=websecure&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--entrypoints.web.http.redirections.entrypoint.scheme=https&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.dnschallenge=true&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.dnschallenge.provider=cloudflare&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.email={{&lt;/span&gt;&lt;span class="nv"&gt; &lt;/span&gt;&lt;span class="s"&gt;traefik_var_CF_API_EMAIL&lt;/span&gt;&lt;span class="nv"&gt; &lt;/span&gt;&lt;span class="s"&gt;}}&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.storage=/acme.json&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;quot;--global.sendAnonymousUsage=false&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;environment&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;CF_API_EMAIL={{ traefik_var_CF_API_EMAIL }}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;CF_API_KEY={{ traefik_var_CF_API_KEY }}&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;ports&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;80:80&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;443:443&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;networks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;ci&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="nt"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/run/docker.sock:/var/run/docker.sock&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/docker/traefik/acme.json:/acme.json&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h2&gt;Somethings remain to be done&lt;/h2&gt;
&lt;p&gt;I'm just testing what needs to be fixed and tweaked
now that drone runs on ssl.&lt;/p&gt;
&lt;p&gt;A few days ago I only set up 1 repo to test, so it needed
its webhooks updated to point to the https new url.&lt;/p&gt;
&lt;p&gt;Also need to fix my test runner as it seems it can't connect
to the drone server so no ci runs are performed. Great.&lt;/p&gt;
&lt;p&gt;Finally got the runner working with the server, had to configure the runner
to use:&lt;/p&gt;
&lt;p&gt;DRONE_RPC_PROTO=http&lt;/p&gt;
&lt;p&gt;instead of&lt;/p&gt;
&lt;p&gt;DRONE_RPC_PROTO=https&lt;/p&gt;
&lt;p&gt;as above.&lt;/p&gt;
&lt;p&gt;I also need to decide how many and what repos I want to locally test.&lt;/p&gt;
&lt;p&gt;Also want to know whether drone can run my ansible roles with molecule.&lt;/p&gt;
&lt;p&gt;Also I'm not a fan of mounting the docker socket into any containers, but
these are running in their own virtual machine at this time.&lt;/p&gt;
&lt;p&gt;Also want to try to upgrade to traefik v2.4.&lt;/p&gt;
&lt;p&gt;Also had to figure out an issue with drone not being able to connect to
my gitea server anymore.&lt;/p&gt;
&lt;p&gt;Turned out it had some routing issues, and I have no idea what messed
up the routing table inside the drone vm as only ansible was modifying it.&lt;/p&gt;
&lt;p&gt;Useful reminder:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;ip&lt;span class="w"&gt; &lt;/span&gt;route&lt;span class="w"&gt; &lt;/span&gt;add&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;192&lt;/span&gt;.168.123.0/24&lt;span class="w"&gt; &lt;/span&gt;via&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;192&lt;/span&gt;.168.122.1
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Another issue that came up while trying to get an ansible role working was
the concept of trusted repos in droneci.&lt;/p&gt;
&lt;p&gt;I forgot to add the docker socket into the pipeline,
so my droneci looks awful like this:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;---&lt;/span&gt;
&lt;span class="n"&gt;kind&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;pipeline&lt;/span&gt;
&lt;span class="n"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;
&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;default&lt;/span&gt;

&lt;span class="n"&gt;steps&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;local&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;build&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="n"&gt;image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;qwe1&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;dind&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;ansible&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;molecule&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;2.9&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;root&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="n"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;dsock&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="k"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;run&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;sock&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="n"&gt;commands&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;ls&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;lah&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;pwd&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;mkdir&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;p&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;~/.&lt;/span&gt;&lt;span class="n"&gt;ansible&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;roles&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;cp&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;aR&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;$(pwd)&amp;quot;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;~/.&lt;/span&gt;&lt;span class="n"&gt;ansible&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;roles&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;richardskumat&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ansible_role_user&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;molecule&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;test&lt;/span&gt;

&lt;span class="n"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;dsock&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="n"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="k"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;run&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;sock&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I didn't specify an admin user for drone when setting up,
so when setting up an ansible role to be tested in drone,
I was getting the following error:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="k"&gt;default&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;linter&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;untrusted&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;repositories&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;cannot&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;mount&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;host&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;volumes&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;So added the following env var to my drone container and it was happy
afterwards:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;DRONE_USER_CREATE=username:user,admin:true
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;username:user in my case had to match the gitea user I was using.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>droneci</title><link href="droneci.html" rel="alternate"></link><published>2021-05-23T12:00:00+01:00</published><updated>2021-05-23T12:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2021-05-23:droneci.html</id><summary type="html">&lt;h1&gt;Droneci&lt;/h1&gt;
&lt;p&gt;I used to run gitlab a while ago, but it was way too
resource heavy for my requirements.&lt;/p&gt;
&lt;p&gt;So far a long time I didn't run any local CI.&lt;/p&gt;
&lt;p&gt;Today, I started playing around &lt;a href="https://docs.drone.io/"&gt;Droneci&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I got it working after some time in its own Debian vm.&lt;/p&gt;
&lt;p&gt;The server …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Droneci&lt;/h1&gt;
&lt;p&gt;I used to run gitlab a while ago, but it was way too
resource heavy for my requirements.&lt;/p&gt;
&lt;p&gt;So far a long time I didn't run any local CI.&lt;/p&gt;
&lt;p&gt;Today, I started playing around &lt;a href="https://docs.drone.io/"&gt;Droneci&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I got it working after some time in its own Debian vm.&lt;/p&gt;
&lt;p&gt;The server runs inside docker and the runner
also runs in the same vm.&lt;/p&gt;
&lt;p&gt;My local git server is a gitea instance, running also
in docker.&lt;/p&gt;
&lt;h2&gt;Link&lt;/h2&gt;
&lt;p&gt;Link for setting up drone with the gitea instance:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://docs.drone.io/server/provider/gitea/"&gt;drone docs gitea link&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Issues&lt;/h2&gt;
&lt;p&gt;I setup the instance of Drone to run on http.&lt;/p&gt;
&lt;p&gt;Which was fine, until I couldn't get the oauth2
auth working between Gitea and Drone.&lt;/p&gt;
&lt;p&gt;Turns out, I setup the Redirect URI as the base
http url instead of http://IP/login.&lt;/p&gt;
&lt;p&gt;Finally managed to get it working, then activated
my blog's git repo, which is a pelican website.&lt;/p&gt;
&lt;p&gt;Then setup the drone runner in docker, which was simple.&lt;/p&gt;
&lt;p&gt;I created a drone.yml file in my git repo,
and pushed it, but nothing happened.&lt;/p&gt;
&lt;p&gt;I looked at my local drone webpage, however it wasn't registering
any activity from the git repo.&lt;/p&gt;
&lt;p&gt;I looked at the git repo's settings and the webhook was configured to
post at HTTPS://IP/what&amp;amp;ever.&lt;/p&gt;
&lt;p&gt;Changed that to http://IP/what&amp;amp;ever and it started working!&lt;/p&gt;
&lt;p&gt;So in my droneci.yml, I configured one step only, which was:&lt;/p&gt;
&lt;p&gt;make publish&lt;/p&gt;
&lt;p&gt;using my pelican &lt;a href="https://hub.docker.com/r/qwe1/docker-pelican"&gt;docker image(qwe1/docker-pelican)&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The makefile in the repo contains a step which
clones the pelican plugins into the git working directory, because
building my website requires some plugins.&lt;/p&gt;
&lt;p&gt;Anyway, at this step I got permission denied errors.&lt;/p&gt;
&lt;p&gt;The user inside my pelican:latest image is uid 1000.&lt;/p&gt;
&lt;p&gt;Turns out, drone clones the source repo as root.&lt;/p&gt;
&lt;p&gt;I found this issue on their forums:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://discourse.drone.io/t/will-clone-build-as-non-root-user-be-supported-self-hosted-and-cloud/9163/3"&gt;post&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I couldn't find a way to chown/chmod the cloned git directory to uid 1000 from root
inside the droneci run, because I was already running as uid 1000
inside the build, so even trying I got permission denied errors.&lt;/p&gt;
&lt;p&gt;I probably could have used a new tag inside my image that has sudo and add
uid 1000 as a passwordless sudoer but that seemed excessive for this use case.&lt;/p&gt;
&lt;p&gt;So instead I made a new tag which runs as root(yay, great) and my test
ci managed to build my website on my 23rd try!&lt;/p&gt;
&lt;p&gt;What a waste of time.&lt;/p&gt;
&lt;h2&gt;To-do?&lt;/h2&gt;
&lt;p&gt;Add a proper hostname to Drone configuration and start using https and hostnames
instead of http and ip-s.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Spring cleaning</title><link href="2021-spring-cleaning.html" rel="alternate"></link><published>2021-05-23T07:30:00+01:00</published><updated>2021-05-23T07:30:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2021-05-23:2021-spring-cleaning.html</id><summary type="html">&lt;h1&gt;Idea of cleaning up projects&lt;/h1&gt;
&lt;p&gt;I've got like 35 or 36 git projects, both public and private that
need some attention.&lt;/p&gt;
&lt;p&gt;In an earlier post, I said I'd do maintenance on them, but
that led me to not even trying anything new.&lt;/p&gt;
&lt;p&gt;If I want to learn more, I have …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Idea of cleaning up projects&lt;/h1&gt;
&lt;p&gt;I've got like 35 or 36 git projects, both public and private that
need some attention.&lt;/p&gt;
&lt;p&gt;In an earlier post, I said I'd do maintenance on them, but
that led me to not even trying anything new.&lt;/p&gt;
&lt;p&gt;If I want to learn more, I have to dig out new stuff, install it,
and play with things.&lt;/p&gt;
&lt;p&gt;I'm talking mainly about kubernetes and also
newer ansible versions.&lt;/p&gt;
&lt;p&gt;I also want to see which projects of mine are worth working on,
which to be honest I don't think any of them are.&lt;/p&gt;
&lt;p&gt;My favourite git repo is still my Dilbert repo, working to this day
somewhat wonky with updates over the years.&lt;/p&gt;
&lt;p&gt;It'd be nice to have all the dilbert downloaded comics locally,
allegedly which that script does.&lt;/p&gt;
&lt;p&gt;I had the idea of rewriting the dilbert scraper in python years ago,
but has also been on hold forever.&lt;/p&gt;
&lt;p&gt;I get these big ideas or thing I want to study or look at/into, and after
I come home from work, I lose all my interest in learning or doing
anything really.&lt;/p&gt;
&lt;p&gt;I remember my French teacher telling me that I should have used my high school
years learning new languages because when I'll grow up I won't have the time
or energy to pursue learning too much stuff.&lt;/p&gt;
&lt;p&gt;It turns out she was right all along.&lt;/p&gt;
&lt;p&gt;The point of this post is self-reflection somewhat, that I need to do things
I want and need and also learn new skills I want to be more valuable and get
ahead with my life.&lt;/p&gt;
&lt;p&gt;Sadly I've been stuck for too long.&lt;/p&gt;
&lt;p&gt;Will that change? Who knows.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Black friday</title><link href="2020-black-friday.html" rel="alternate"></link><published>2020-11-27T18:00:00+00:00</published><updated>2020-11-27T18:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-11-27:2020-black-friday.html</id><summary type="html">&lt;h1&gt;Buy buy buy&lt;/h1&gt;
&lt;p&gt;As a good little consumer I haven't bought anything for
black friday.&lt;/p&gt;
&lt;p&gt;I planned on getting a cheap xiaomi phone again,
but nothing's in sight yet.&lt;/p&gt;
&lt;p&gt;I also thought about building a new pc, but why
would I?&lt;/p&gt;
&lt;p&gt;The last desktop I built was about 4 years …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Buy buy buy&lt;/h1&gt;
&lt;p&gt;As a good little consumer I haven't bought anything for
black friday.&lt;/p&gt;
&lt;p&gt;I planned on getting a cheap xiaomi phone again,
but nothing's in sight yet.&lt;/p&gt;
&lt;p&gt;I also thought about building a new pc, but why
would I?&lt;/p&gt;
&lt;p&gt;The last desktop I built was about 4 years ago, and
it's still OK. Not great anymore, but still
does the job.&lt;/p&gt;
&lt;p&gt;I noticed I haven't posted anything in 4 months,
but with this lockdown happening nothing's
worth writing about, which is pretty
fscking depressing.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>A nifty find one liner</title><link href="find-mv-cmd.html" rel="alternate"></link><published>2020-07-16T11:00:00+01:00</published><updated>2020-07-16T11:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-07-16:find-mv-cmd.html</id><summary type="html">&lt;h1&gt;What this does&lt;/h1&gt;
&lt;p&gt;This find command finds and moves all directories to
/dest/dir that matches the '&lt;em&gt;dirnamepattern&lt;/em&gt;'.&lt;/p&gt;
&lt;p&gt;'&lt;em&gt;dirnamepattern&lt;/em&gt;' could be aws, go or tmp, or whatever.&lt;/p&gt;
&lt;h2&gt;Actual command&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;find&lt;span class="w"&gt; &lt;/span&gt;.&lt;span class="w"&gt; &lt;/span&gt;-type&lt;span class="w"&gt; &lt;/span&gt;d&lt;span class="w"&gt; &lt;/span&gt;-name&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;*dirnamepattern*&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-exec&lt;span class="w"&gt; &lt;/span&gt;mv&lt;span class="w"&gt; &lt;/span&gt;-t&lt;span class="w"&gt; &lt;/span&gt;/dest/dir&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;{}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;+
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h3&gt;Test before try&lt;/h3&gt;
&lt;p&gt;I'm not sure if there's a dry run …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;What this does&lt;/h1&gt;
&lt;p&gt;This find command finds and moves all directories to
/dest/dir that matches the '&lt;em&gt;dirnamepattern&lt;/em&gt;'.&lt;/p&gt;
&lt;p&gt;'&lt;em&gt;dirnamepattern&lt;/em&gt;' could be aws, go or tmp, or whatever.&lt;/p&gt;
&lt;h2&gt;Actual command&lt;/h2&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;find&lt;span class="w"&gt; &lt;/span&gt;.&lt;span class="w"&gt; &lt;/span&gt;-type&lt;span class="w"&gt; &lt;/span&gt;d&lt;span class="w"&gt; &lt;/span&gt;-name&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;*dirnamepattern*&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-exec&lt;span class="w"&gt; &lt;/span&gt;mv&lt;span class="w"&gt; &lt;/span&gt;-t&lt;span class="w"&gt; &lt;/span&gt;/dest/dir&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;{}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;+
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h3&gt;Test before try&lt;/h3&gt;
&lt;p&gt;I'm not sure if there's a dry run to find's exec, but the above command
can be modified to output matching directories with a simple echo
variation:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;find&lt;span class="w"&gt; &lt;/span&gt;.&lt;span class="w"&gt; &lt;/span&gt;-type&lt;span class="w"&gt; &lt;/span&gt;d&lt;span class="w"&gt; &lt;/span&gt;-name&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;*dirnamepattern*&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-exec&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;{}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;+
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</content><category term="posts"></category></entry><entry><title>Debian Jessie(8) end of life</title><link href="debian-jessie-eol.html" rel="alternate"></link><published>2020-07-15T20:00:00+01:00</published><updated>2020-07-15T20:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-07-15:debian-jessie-eol.html</id><summary type="html">&lt;h1&gt;Special release&lt;/h1&gt;
&lt;p&gt;Jessie was my first version of Debian I've installed
on my acer laptop back in 2015.&lt;/p&gt;
&lt;p&gt;Nowadays, all my things run Buster, but it's still
awful to think how fast time goes and
Debian releases come and go.&lt;/p&gt;
&lt;h2&gt;Related link&lt;/h2&gt;
&lt;p&gt;I just saw today this debian news page …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Special release&lt;/h1&gt;
&lt;p&gt;Jessie was my first version of Debian I've installed
on my acer laptop back in 2015.&lt;/p&gt;
&lt;p&gt;Nowadays, all my things run Buster, but it's still
awful to think how fast time goes and
Debian releases come and go.&lt;/p&gt;
&lt;h2&gt;Related link&lt;/h2&gt;
&lt;p&gt;I just saw today this debian news page in
my rss feed:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://www.debian.org/News/2020/20200709"&gt;https://www.debian.org/News/2020/20200709&lt;/a&gt;&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>An issue I ran into when creating a new Gitlab repo with terraform</title><link href="gitlab-terraform-new-repo-created-gotcha.html" rel="alternate"></link><published>2020-07-02T20:45:00+01:00</published><updated>2020-07-02T20:45:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-07-02:gitlab-terraform-new-repo-created-gotcha.html</id><summary type="html">&lt;h1&gt;Gitlab + Terraform&lt;/h1&gt;
&lt;p&gt;I try to manage my gitlab repos via terraform
lately.&lt;/p&gt;
&lt;p&gt;Yesterday, I created a new project called
&lt;a href="https://gitlab.com/richardskumat/ansible-role-chrome"&gt;ansible-role-chrome&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;This was done with terraform.&lt;/p&gt;
&lt;p&gt;The project has a gitlabci file that
runs molecule test in two Debian 9&amp;amp;10
images of mine.&lt;/p&gt;
&lt;p&gt;Today I got an email saying that …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Gitlab + Terraform&lt;/h1&gt;
&lt;p&gt;I try to manage my gitlab repos via terraform
lately.&lt;/p&gt;
&lt;p&gt;Yesterday, I created a new project called
&lt;a href="https://gitlab.com/richardskumat/ansible-role-chrome"&gt;ansible-role-chrome&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;This was done with terraform.&lt;/p&gt;
&lt;p&gt;The project has a gitlabci file that
runs molecule test in two Debian 9&amp;amp;10
images of mine.&lt;/p&gt;
&lt;p&gt;Today I got an email saying that my CI failed
on this new repo, whereas I had molecule
tests working locally.&lt;/p&gt;
&lt;p&gt;I found out that when creating the repo with
terraform apply, shared runners were disabled
for this repo.&lt;/p&gt;
&lt;p&gt;After looking at the
&lt;a href="https://www.terraform.io/docs/providers/gitlab/r/project.html"&gt;gitlab project resource docs&lt;/a&gt;,
I saw there's a shared_runners_enabled argument.&lt;/p&gt;
&lt;p&gt;My resource block of course didn't
contain the following line:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="nv"&gt;shared_runners_enabled&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;true&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;The whole block now looks like this:&lt;/p&gt;
&lt;pre&gt;
resource "gitlab_project" "ansible-role-chrome" {
    name = "ansible-role-chrome"
    description = "this is the ansible-role-chrome repo"
    visibility_level = "public"
    request_access_enabled = false
    default_branch = "master"
    merge_requests_enabled = true
    issues_enabled = true
    wiki_enabled = false
    shared_runners_enabled = true
}
&lt;/pre&gt;

&lt;p&gt;So now I've got shared runners enabled
for this project and now of course my
molecule tests passed. Yay.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Some of the docker images I use</title><link href="docker-images-used.html" rel="alternate"></link><published>2020-06-26T13:15:00+01:00</published><updated>2020-06-26T13:15:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-06-26:docker-images-used.html</id><summary type="html">&lt;h1&gt;My own Docker images&lt;/h1&gt;
&lt;p&gt;I maintain a couple of docker images for myself
on Dockerhub(about 9 active) at the following link,
under user qwe1:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/u/qwe1"&gt;https://hub.docker.com/u/qwe1&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Other images used&lt;/h2&gt;
&lt;p&gt;I use many images from linuxserver.io, such
as sonarr, radarr, jackett and jellyfin.&lt;/p&gt;
&lt;p&gt;Bazarr is …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;My own Docker images&lt;/h1&gt;
&lt;p&gt;I maintain a couple of docker images for myself
on Dockerhub(about 9 active) at the following link,
under user qwe1:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/u/qwe1"&gt;https://hub.docker.com/u/qwe1&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Other images used&lt;/h2&gt;
&lt;p&gt;I use many images from linuxserver.io, such
as sonarr, radarr, jackett and jellyfin.&lt;/p&gt;
&lt;p&gt;Bazarr is also great to get subtitles and
to be honest, it works OK most of the time.&lt;/p&gt;
&lt;p&gt;I also like to use mariadb:10.4 and traefik:2.2.&lt;/p&gt;
&lt;p&gt;It took me some time to get a working config
for the new traefik 2.x docker image.&lt;/p&gt;
&lt;p&gt;I had to ditch my previous method of using a toml
file and some ansible hackery.&lt;/p&gt;
&lt;p&gt;Nowadays, I just run traefik with a long command
line from a docker compose file.&lt;/p&gt;
&lt;p&gt;A traefik example from an ansible docker-compose file:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="n"&gt;traefik&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;traefik&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mf"&gt;2.2&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;restart&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;unless&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;stopped&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;container_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;traefik&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;command&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--providers.docker=true&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--providers.docker.exposedbydefault=false&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--entrypoints.web.address=:80&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--entrypoints.websecure.address=:443&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--entrypoints.web.http.redirections.entrypoint.to=websecure&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--entrypoints.web.http.redirections.entrypoint.scheme=https&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.dnschallenge=true&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.dnschallenge.provider=cloudflare&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.email={{ var1 }}&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--certificatesresolvers.myresolver.acme.storage=/acme.json&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;--global.sendAnonymousUsage=false&amp;quot;&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;environment&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;CF_API_EMAIL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;var1&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}}&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;CF_API_KEY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;var2&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}}&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;ports&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;80&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;80&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;443&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;443&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;networks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;desktop_network&lt;/span&gt;
&lt;span class="w"&gt;         &lt;/span&gt;&lt;span class="n"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="k"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;run&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;sock&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="k"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;run&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;sock&lt;/span&gt;
&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="k"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;docker&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;traefik&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;acme&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;acme&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Some other images I use are php:7.3-apache-buster
for 2 dokuwiki instances.&lt;/p&gt;
&lt;p&gt;I also have a gitea instance running with mariadb
database.&lt;/p&gt;
&lt;p&gt;I like to wait a bit before upgrading my gitea
instance to see if there are issues with a release.&lt;/p&gt;
&lt;p&gt;I also run a pihole instance with host networking on
a laptop, and it functions OK as a dns and dhcp
server.&lt;/p&gt;
&lt;p&gt;I made a mistake by leaving my pihole tag at latest,
so when the latest release came out(v5.0), I accidently
got upgraded to 5.0.&lt;/p&gt;
&lt;p&gt;I haven't issues with the new version, it's just I wanted
to wait a few weeks for issues to be ironed out.&lt;/p&gt;
&lt;p&gt;I also have a draw.io image running, image:&lt;/p&gt;
&lt;p&gt;fjudith/draw.io:alpine&lt;/p&gt;
&lt;p&gt;I run a local version of &lt;a href="https://meyerweb.com/eric/tools/dencoder/"&gt;js dencoder&lt;/a&gt;,
which is useful for decoding some garbage URLs found
on the web with httpd:alpine image.&lt;/p&gt;
&lt;p&gt;What's special about the httpd:alpine image is that the
default web root is /usr/local/apache2/htdocs, instead of
/var/www/html as found in the debian based httpd
images.&lt;/p&gt;
&lt;p&gt;This caught me as a surprise when I tried running the alpine
image the first time.&lt;/p&gt;
&lt;h3&gt;How I try to track docker images tags and releases&lt;/h3&gt;
&lt;p&gt;I am subscribed to a bunch of Github RSS feeds
and frequently review new releases for any issues
before doing any major upgrades.&lt;/p&gt;
&lt;p&gt;Fortunately, linuxserver.io has Github repos
for docker images and their git tags match their
docker tags.&lt;/p&gt;
&lt;p&gt;This is all manual and can be tedious,
but I try to to avoid using
latest tags where possible.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>pgrep</title><link href="pgrep.html" rel="alternate"></link><published>2020-06-20T14:30:00+01:00</published><updated>2020-06-20T14:30:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-06-20:pgrep.html</id><summary type="html">&lt;h1&gt;Pgrep&lt;/h1&gt;
&lt;p&gt;I've got a few shell scripts in a private repo
and I recently wrote another to kill my vlc
instances because it seems to hang up sometimes
on Debian 10 when playing files from my
junk hp microserver.&lt;/p&gt;
&lt;p&gt;So I wrote something idiotic like this to kill vlc:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="nb"&gt;kill …&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</summary><content type="html">&lt;h1&gt;Pgrep&lt;/h1&gt;
&lt;p&gt;I've got a few shell scripts in a private repo
and I recently wrote another to kill my vlc
instances because it seems to hang up sometimes
on Debian 10 when playing files from my
junk hp microserver.&lt;/p&gt;
&lt;p&gt;So I wrote something idiotic like this to kill vlc:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="nb"&gt;kill&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-9&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;$(&lt;/span&gt;ps&lt;span class="w"&gt; &lt;/span&gt;auxf&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;grep&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;[v]lc&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;awk&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;{print $2}&amp;#39;&lt;/span&gt;&lt;span class="k"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Then comes my Gitlab ci result saying I'm an idiot
and should use pgrep instead.&lt;/p&gt;
&lt;p&gt;So now I've got something like this which the linter is
happy with:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="nb"&gt;kill&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-9&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;&lt;span class="k"&gt;$(&lt;/span&gt;pgrep&lt;span class="w"&gt; &lt;/span&gt;-u&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;&lt;span class="k"&gt;$(&lt;/span&gt;whoami&lt;span class="k"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;vlc&lt;span class="k"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h2&gt;Improvements to linting&lt;/h2&gt;
&lt;p&gt;I need to look into how I could do linting before
making git commits from inside vscode, where
I code mostly.&lt;/p&gt;
&lt;p&gt;I've found the following extension:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/magicmark/pre-commit-vscode"&gt;https://github.com/magicmark/pre-commit-vscode&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://marketplace.visualstudio.com/items?itemName=MarkLarah.pre-commit-vscode"&gt;https://marketplace.visualstudio.com/items?itemName=MarkLarah.pre-commit-vscode&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I'll have to test it how well
it integrates with latest vscode.&lt;/p&gt;</content><category term="posts"></category></entry><entry><title>Recent things</title><link href="20200619-recent-things.html" rel="alternate"></link><published>2020-06-19T19:30:00+01:00</published><updated>2020-06-19T19:30:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-06-19:20200619-recent-things.html</id><summary type="html">&lt;h1&gt;What's been going&lt;/h1&gt;
&lt;p&gt;I haven't posted in 2 months, as I was focusing
on work.&lt;/p&gt;
&lt;p&gt;In the meantime, I was focusing on maintaining
my private code repos and thinking about
ways of what I could improve in my public and
private projects.&lt;/p&gt;
&lt;h2&gt;What I'm going to do&lt;/h2&gt;
&lt;p&gt;I've got nothing …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;What's been going&lt;/h1&gt;
&lt;p&gt;I haven't posted in 2 months, as I was focusing
on work.&lt;/p&gt;
&lt;p&gt;In the meantime, I was focusing on maintaining
my private code repos and thinking about
ways of what I could improve in my public and
private projects.&lt;/p&gt;
&lt;h2&gt;What I'm going to do&lt;/h2&gt;
&lt;p&gt;I've got nothing specific to write here,
it's just I feel that stuff I already have
running at home are running OK, not great
but not bad either.&lt;/p&gt;
&lt;p&gt;What I could improve on is automating more
things(like bare metal reinstalls) and
setting up a centralized logging system.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Simple ansible logrotate script</title><link href="20200418-ansible-logrotate-script.html" rel="alternate"></link><published>2020-04-18T10:00:00+01:00</published><updated>2020-04-18T10:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-04-18:20200418-ansible-logrotate-script.html</id><summary type="html">&lt;h1&gt;Ansible logs&lt;/h1&gt;
&lt;p&gt;Ansible logs details of playbooks runs
into files defined with the:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;log_path = /path/text.log
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;variable if defined in the ansible.cfg file.&lt;/p&gt;
&lt;p&gt;For my simple personal use cases, I turned logging
on and for a while did nothing with the logfile.&lt;/p&gt;
&lt;p&gt;After several months, the first log …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Ansible logs&lt;/h1&gt;
&lt;p&gt;Ansible logs details of playbooks runs
into files defined with the:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;log_path = /path/text.log
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;variable if defined in the ansible.cfg file.&lt;/p&gt;
&lt;p&gt;For my simple personal use cases, I turned logging
on and for a while did nothing with the logfile.&lt;/p&gt;
&lt;p&gt;After several months, the first log file turned
into several thousand lines long.&lt;/p&gt;
&lt;p&gt;I wrote a fairly simple shell scrip to do basic
logrotating with the ansible log file.&lt;/p&gt;
&lt;p&gt;I uploaded this script to a Github gist,
with the raw script link being:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gist.githubusercontent.com/richardskumat/5e123ee95a71f7e2c578028173b78dda/raw/258a00ecd9576411bc24fb6183fff46db2b0d665/ansible-log-rotate.sh"&gt;ansible-log-rotate.sh&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;There's also a Gitlab copy of this script:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/snippets/1967652/raw"&gt;ansible-log-rotate.sh&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Cron job&lt;/h2&gt;
&lt;p&gt;I run a cron job monthly, which looks like this:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="c1"&gt;#Ansible: monthly ansible logrotate&lt;/span&gt;
@monthly&lt;span class="w"&gt; &lt;/span&gt;bash&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;/path/scripts/ansible-log-rotate&lt;span class="w"&gt;  &lt;/span&gt;&amp;gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="si"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;LOG_FILE_PATH&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;/ansible-logrotate-&lt;span class="k"&gt;$(&lt;/span&gt;date&lt;span class="w"&gt; &lt;/span&gt;+&lt;span class="se"&gt;\%&lt;/span&gt;Y-&lt;span class="se"&gt;\%&lt;/span&gt;m-&lt;span class="se"&gt;\%&lt;/span&gt;d-&lt;span class="se"&gt;\%&lt;/span&gt;H-&lt;span class="se"&gt;\%&lt;/span&gt;M-&lt;span class="se"&gt;\%&lt;/span&gt;S&lt;span class="k"&gt;)&lt;/span&gt;.log&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;2&lt;/span&gt;&amp;gt;&lt;span class="p"&gt;&amp;amp;&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;This way the log rotate scripts runs every month, on the first of month
at midnight.&lt;/p&gt;
&lt;p&gt;I've been running this script with cron for a few months,
and it resulted in the following tar.gz files,
which are readable with zcat:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;ansible.log&lt;span class="w"&gt;             &lt;/span&gt;ansible.log-2019-12-01-00-00-01.tar.gz
ansible-log-201907310913.tar.gz&lt;span class="w"&gt;     &lt;/span&gt;ansible.log-2020-01-01-00-00-01.tar.gz
ansible.log-2019-09-01-00-00-01.tar.gz&lt;span class="w"&gt;  &lt;/span&gt;ansible.log-2020-02-01-00-00-01.tar.gz
ansible.log-2019-10-01-00-00-01.tar.gz&lt;span class="w"&gt;  &lt;/span&gt;ansible.log-2020-03-01-00-00-01.tar.gz
ansible.log-2019-11-01-00-00-01.tar.gz&lt;span class="w"&gt;  &lt;/span&gt;ansible.log-2020-04-01-00-00-01.tar.gz
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Of course, a lot better way would be to ship these log files
to a central log server, but for a personal use case I find
these adequate.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Gmail settings for Thunderbird with a Gsuite account</title><link href="20200415-gmail-settings-gsuite-thunderbird.html" rel="alternate"></link><published>2020-04-15T13:00:00+01:00</published><updated>2020-04-15T13:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-04-15:20200415-gmail-settings-gsuite-thunderbird.html</id><summary type="html">&lt;h1&gt;My issue with sending emails&lt;/h1&gt;
&lt;p&gt;I've been using Thunderbird(TB) for 3-4 years with a couple
email addresses and it has served me well so far.&lt;/p&gt;
&lt;p&gt;Last year, I've moved my email address over to Google's
Gsuite service and when sending emails sometimes
I'd get an error that TB could …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;My issue with sending emails&lt;/h1&gt;
&lt;p&gt;I've been using Thunderbird(TB) for 3-4 years with a couple
email addresses and it has served me well so far.&lt;/p&gt;
&lt;p&gt;Last year, I've moved my email address over to Google's
Gsuite service and when sending emails sometimes
I'd get an error that TB could not login to Gmail.&lt;/p&gt;
&lt;p&gt;So then &lt;a href="https://myaccount.google.com/security"&gt;I'd login&lt;/a&gt; and enable the "unsecure"
"Access to less secure apps" to ON.&lt;/p&gt;
&lt;p&gt;However, Google turns this off if it thinks
you're not using it, eg not sending emails
all the time. And there's no option to change
this behaviour.&lt;/p&gt;
&lt;p&gt;I was getting the same error as the poster
on the &lt;a href="http://forums.mozillazine.org/viewtopic.php?f=39&amp;amp;t=3056790"&gt;mozilla forums&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Namely, the following error:&lt;/p&gt;
&lt;pre&gt;
error message from send: Sending of the message failed.
Failed due to unexpected error 80004005. No description is available.
The message could not be sent using Outgoing server (SMTP) smtp.gmail.com for an unknown reason.
Please verify that your Outgoing server (SMTP) settings are correct and try again.
&lt;/pre&gt;

&lt;h2&gt;What I've tried&lt;/h2&gt;
&lt;p&gt;On the linux version of TB, I went to Edit/Account Settings and
had a look at my primary email's "Server settings".&lt;/p&gt;
&lt;p&gt;The following is how the incoming settings are:&lt;/p&gt;
&lt;pre&gt;
Server Type: Imap
Server name: imap.gmail.com
Port: 993
Username: whatever@mydomain.tld

Security Settings:
Connection Security: SSL/TLS
Authentication method: OAuth2
&lt;/pre&gt;

&lt;p&gt;All of this seem to have continued working since my
email migration from OVH's email service.&lt;/p&gt;
&lt;p&gt;On the Outgoing Server (SMTP) part of TB settings,
I had my Gsuite labelled gmail settings configured as follows:&lt;/p&gt;
&lt;pre&gt;
Description: Gsuite
Server name: smtp.gmail.com
Port: 465

Security &amp; Authentication:
Connection Security: SSL/TLS
Authentication method: Normal Password
User name: whatever@mydomain.tld
&lt;/pre&gt;

&lt;p&gt;As per the first poster on the &lt;a href="http://forums.mozillazine.org/viewtopic.php?f=39&amp;amp;t=3056790"&gt;link above&lt;/a&gt;,
I've changed Auth method to Oauth2.&lt;/p&gt;
&lt;p&gt;Then proceeded to turn off "Access to less secure apps".&lt;/p&gt;
&lt;p&gt;So now my updated SMTP settings look like this:&lt;/p&gt;
&lt;pre&gt;
Description: Gsuite
Server name: smtp.gmail.com
Port: 465

Security &amp; Authentication:
Connection Security: SSL/TLS
Authentication method: Oauth2
User name: whatever@mydomain.tld
&lt;/pre&gt;

&lt;p&gt;So now I can happily send messages without getting
the dreaded "unexpected error 80004005".&lt;/p&gt;
&lt;h2&gt;Relevant links&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://gsuiteupdates.googleblog.com/2019/12/less-secure-apps-oauth-google-username-password-incorrect.html"&gt;G suite updates blog&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://www.theregister.co.uk/2019/12/17/google_tightens_the_screw_on_less_secure_apps_will_block_most_access_from_june_2020/"&gt;theregister's take on the above announcement&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/k9mail/k-9/issues/655"&gt;k9-mail oauth2 support&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/k9mail/k-9/pull/3804"&gt;k9-mail oauth2 pr&lt;/a&gt;&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Terraform git repo removal with Gitlab provider</title><link href="20200404-terraform-remove-gitlab-repo.html" rel="alternate"></link><published>2020-04-04T10:30:00+01:00</published><updated>2020-04-04T10:30:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-04-04:20200404-terraform-remove-gitlab-repo.html</id><summary type="html">&lt;h1&gt;New changes on Gitlab&lt;/h1&gt;
&lt;p&gt;I haven't deleted a git repo on Gitlab for some time,
so I didn't know about a "feature" Gitlab created.&lt;/p&gt;
&lt;p&gt;Now on the public Gitlab.com instance, if you try
to remove/delete a repo, it defaults into an
archived form for 7 days before it's …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;New changes on Gitlab&lt;/h1&gt;
&lt;p&gt;I haven't deleted a git repo on Gitlab for some time,
so I didn't know about a "feature" Gitlab created.&lt;/p&gt;
&lt;p&gt;Now on the public Gitlab.com instance, if you try
to remove/delete a repo, it defaults into an
archived form for 7 days before it's removed.&lt;/p&gt;
&lt;p&gt;Here's the Gitlab issue about this:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/gitlab-org/gitlab/issues/32935"&gt;gitlab-org/gitlab/issues/32935&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Also if you try to delete a fork of a repo,
it also goes into read-only mode for 7 days
as per &lt;a href="https://gitlab.com/gitlab-com/support-forum/-/issues/5335"&gt;this issue&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Other relevant issues&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/gitlab-org/gitlab/issues/191367"&gt;Gitlab/Immediately remove a soft-deleted project&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/terraform-providers/terraform-provider-gitlab/issues/263"&gt;Github,TF/Gitlab introduced soft delete of projects and groups&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/terraform-providers/terraform-provider-gitlab/issues/133"&gt;Github,TF/Project Roadmap&lt;/a&gt;&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Working with the Gitlab provider for Terraform</title><link href="20200318-gitlab-terraform-provider.html" rel="alternate"></link><published>2020-03-18T16:00:00+00:00</published><updated>2020-03-18T16:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-03-18:20200318-gitlab-terraform-provider.html</id><summary type="html">&lt;h1&gt;More Terraform work&lt;/h1&gt;
&lt;p&gt;I've got a few git repositories on Gitlab.com
that have been manually made over time, with different
configurations, ci schedules and purposes.&lt;/p&gt;
&lt;p&gt;I consider them to be a giant mess at this point, so
with some of my recent work I wanted to reorganise all
of …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;More Terraform work&lt;/h1&gt;
&lt;p&gt;I've got a few git repositories on Gitlab.com
that have been manually made over time, with different
configurations, ci schedules and purposes.&lt;/p&gt;
&lt;p&gt;I consider them to be a giant mess at this point, so
with some of my recent work I wanted to reorganise all
of it for the better.&lt;/p&gt;
&lt;h2&gt;Terraform(TF) with Gitlab&lt;/h2&gt;
&lt;p&gt;Since I like both TF and Gitlab, I thought it'd be
a great time to make them work together.&lt;/p&gt;
&lt;p&gt;TF has a &lt;a href="https://www.terraform.io/docs/providers/gitlab/index.html"&gt;Gitlab provider&lt;/a&gt;
 that I could use.&lt;/p&gt;
&lt;p&gt;After a lot of trial and errors, I managed to use a
few features of the Gitlab provider for my
needs and have posted some sample
code to a &lt;a href="https://gitlab.com/richardskumat/public-terraform-examples/-/tree/master/20200315_gitlab"&gt;Gitlab.com repo&lt;/a&gt; for others to
view.&lt;/p&gt;
&lt;h3&gt;What's in the repo&lt;/h3&gt;
&lt;p&gt;There's some sample terraform(.tf) code, some shell
utility scripts and also some Ansible code I
used for templating some terraform resource
configuration blocks.&lt;/p&gt;
&lt;p&gt;I learned a lot of new things doing this for myself
and am happy with the outcome.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Molecule tests</title><link href="20200216-molecule-tests.html" rel="alternate"></link><published>2020-02-16T16:00:00+00:00</published><updated>2020-02-16T16:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-02-16:20200216-molecule-tests.html</id><summary type="html">&lt;h1&gt;Update on 2020-02-23&lt;/h1&gt;
&lt;p&gt;Turns out this doesn't work at all, all the time.&lt;/p&gt;
&lt;h2&gt;Some notes for myself regarding molecule testing&lt;/h2&gt;
&lt;p&gt;I recently removed my everyday user from the docker group,
so programs running under my user can't run arbitrary docker
commands anymore. Wooho.&lt;/p&gt;
&lt;h2&gt;Sudo with docker instead&lt;/h2&gt;
&lt;p&gt;The original post …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Update on 2020-02-23&lt;/h1&gt;
&lt;p&gt;Turns out this doesn't work at all, all the time.&lt;/p&gt;
&lt;h2&gt;Some notes for myself regarding molecule testing&lt;/h2&gt;
&lt;p&gt;I recently removed my everyday user from the docker group,
so programs running under my user can't run arbitrary docker
commands anymore. Wooho.&lt;/p&gt;
&lt;h2&gt;Sudo with docker instead&lt;/h2&gt;
&lt;p&gt;The original post I had here wasn't working after all,
so I decided to remove it.&lt;/p&gt;
&lt;p&gt;I don't know how I got it to work.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Finished working on my Docker ansible role for now</title><link href="ansible-role-docker-updated.html" rel="alternate"></link><published>2020-02-02T16:00:00+00:00</published><updated>2020-02-02T16:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-02-02:ansible-role-docker-updated.html</id><summary type="html">&lt;h1&gt;Merged some commits in my docker role&lt;/h1&gt;
&lt;p&gt;After some work on the docker ansible role, I merged my own
commits from dev branch to master.&lt;/p&gt;
&lt;p&gt;The list commits can be found here with comments in the
git log detailing the changes.&lt;/p&gt;
&lt;p&gt;Here's the &lt;a href="https://gitlab.com/richardskumat/ansible-role-docker/commits/master"&gt;Gitlab.com link for commit history&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Of …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Merged some commits in my docker role&lt;/h1&gt;
&lt;p&gt;After some work on the docker ansible role, I merged my own
commits from dev branch to master.&lt;/p&gt;
&lt;p&gt;The list commits can be found here with comments in the
git log detailing the changes.&lt;/p&gt;
&lt;p&gt;Here's the &lt;a href="https://gitlab.com/richardskumat/ansible-role-docker/commits/master"&gt;Gitlab.com link for commit history&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Of course, I wouldn't recommend using my own role for anyone but myself,
instead I would point people to &lt;a href="https://github.com/geerlingguy/ansible-role-docker"&gt;Jeff Geerling's docker role on Github&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;His role has a lot more work, commits and features added.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>New Docker images</title><link href="new-docker-images.html" rel="alternate"></link><published>2020-01-12T16:00:00+00:00</published><updated>2020-01-12T16:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-01-12:new-docker-images.html</id><summary type="html">&lt;h1&gt;Two new docker images&lt;/h1&gt;
&lt;p&gt;I'll be building some of my own CentOS
and Debian images for molecule testing,
hopefully to cut down on molecule testing
time.&lt;/p&gt;
&lt;p&gt;These are:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-debian"&gt;Debian&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-centos"&gt;CentOS&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Source code to repos&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/richardskumat/docker-debian"&gt;docker-debian&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/richardskumat/docker-centos"&gt;docker-centos&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The build logs are public as well.&lt;/p&gt;
&lt;h2&gt;Now they're done&lt;/h2&gt;
&lt;p&gt;At least they're now …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Two new docker images&lt;/h1&gt;
&lt;p&gt;I'll be building some of my own CentOS
and Debian images for molecule testing,
hopefully to cut down on molecule testing
time.&lt;/p&gt;
&lt;p&gt;These are:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-debian"&gt;Debian&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-centos"&gt;CentOS&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Source code to repos&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/richardskumat/docker-debian"&gt;docker-debian&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/richardskumat/docker-centos"&gt;docker-centos&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The build logs are public as well.&lt;/p&gt;
&lt;h2&gt;Now they're done&lt;/h2&gt;
&lt;p&gt;At least they're now usable for my Ansible &amp;amp; Molecule tests.&lt;/p&gt;
&lt;p&gt;These images are built from upstream Debian/CentOS images
and Gitlab CI pushes them to Dockerhub and Gitlab registries.&lt;/p&gt;
&lt;h2&gt;Tags&lt;/h2&gt;
&lt;p&gt;Some of the tags can be seen here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-debian/tags"&gt;Debian image tags&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://hub.docker.com/r/qwe1/docker-centos/tags"&gt;CentOS image tags&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;For my own use, I like to use the distro:releaseversion-molecule tags
with molecule.&lt;/p&gt;
&lt;p&gt;They have '/lib/systemd/systemd' set as cmd-s, so I can use them the
same way in ansible role tests.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Update on my Docker Ansible role</title><link href="ansible-role-docker-update.html" rel="alternate"></link><published>2020-01-12T15:30:00+00:00</published><updated>2020-01-12T15:30:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2020-01-12:ansible-role-docker-update.html</id><summary type="html">&lt;h1&gt;New year, old projects&lt;/h1&gt;
&lt;p&gt;People love working on new things all the time, however
I've got lots of repos on &lt;a href="https://gitlab.com/richardskumat"&gt;Gitlab.com&lt;/a&gt;
that I want keep updated for myself.&lt;/p&gt;
&lt;p&gt;One of those projects is this blog, which source code
I've taken private permanently.&lt;/p&gt;
&lt;p&gt;However, other projects that I've recently updated …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;New year, old projects&lt;/h1&gt;
&lt;p&gt;People love working on new things all the time, however
I've got lots of repos on &lt;a href="https://gitlab.com/richardskumat"&gt;Gitlab.com&lt;/a&gt;
that I want keep updated for myself.&lt;/p&gt;
&lt;p&gt;One of those projects is this blog, which source code
I've taken private permanently.&lt;/p&gt;
&lt;p&gt;However, other projects that I've recently updated are my
docker images' projects and some of my
Ansible roles.&lt;/p&gt;
&lt;h2&gt;Why update my own Ansible roles that I only use myself&lt;/h2&gt;
&lt;p&gt;Times change and new distros come out.&lt;/p&gt;
&lt;p&gt;Plus most of my roles are just bare enough to get my
own personal systems running, however they wouldn't
get any praise in a work environment.&lt;/p&gt;
&lt;p&gt;I've learned lots from &lt;a href="https://github.com/geerlingguy"&gt;Jeff Geerling's Ansible roles on Github&lt;/a&gt;,
also from &lt;a href="https://github.com/weareinteractive"&gt;https://github.com/weareinteractive&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I'm currently trying to update my Docker ansible role to make it a bit better.&lt;/p&gt;
&lt;p&gt;In hindsight, I should have just used &lt;a href="https://github.com/geerlingguy/ansible-role-docker"&gt;Jeff Geerling's docker repo&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;What's being updated in my Docker role&lt;/h2&gt;
&lt;p&gt;I'm trying to add Centos support and improve some other aspects of it.&lt;/p&gt;
&lt;p&gt;I want to add a new task and make it configurable whether to add/remove any users
to/from the docker group.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://gitlab.com/richardskumat/ansible-role-docker/issues/"&gt;Here's a list of issues&lt;/a&gt; for this role.&lt;/p&gt;
&lt;p&gt;I'm currently working on the dev branch.&lt;/p&gt;
&lt;p&gt;I've posted an update in &lt;a href="../ansible-role-docker-updated.html"&gt;the following post&lt;/a&gt;.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Day-off project: Retropie</title><link href="retropie.html" rel="alternate"></link><published>2019-12-11T21:00:00+00:00</published><updated>2019-12-11T21:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-12-11:retropie.html</id><summary type="html">&lt;h1&gt;Madness in boxes&lt;/h1&gt;
&lt;p&gt;So around black friday I was running through my
card board boxes that have all sorts of cables
and other PC accessories.&lt;/p&gt;
&lt;p&gt;I wanted to a buy a new mouse for my desktop,
because the previous one's scroll wheel
was pushing me into madness.&lt;/p&gt;
&lt;p&gt;But I managed …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Madness in boxes&lt;/h1&gt;
&lt;p&gt;So around black friday I was running through my
card board boxes that have all sorts of cables
and other PC accessories.&lt;/p&gt;
&lt;p&gt;I wanted to a buy a new mouse for my desktop,
because the previous one's scroll wheel
was pushing me into madness.&lt;/p&gt;
&lt;p&gt;But I managed to find a usb mouse that was
from ASDA and it was still in its original
box.&lt;/p&gt;
&lt;p&gt;Here, I got the idea that I wanted to put
my other boxed/packaged things to use as well.&lt;/p&gt;
&lt;p&gt;I've two Raspberry Pis from years ago and
I used them a lot for years.&lt;/p&gt;
&lt;p&gt;Then I put them into these boxes, because managing
four x64 machines were a lot simpler after moving,than
mixing armhf and x64 arches.&lt;/p&gt;
&lt;p&gt;I'm mostly referring to
building my own docker images and starting to write
my own ansible playbooks.&lt;/p&gt;
&lt;p&gt;Focusing only on one arch at the time seemed to be
a better idea.&lt;/p&gt;
&lt;h2&gt;Raspberry Pis&lt;/h2&gt;
&lt;p&gt;I wrote a post on wanting to make these &lt;a href="../old-pi.html"&gt;Pis
useful again here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;As update to that previous post,
I managed to find a functioning SD card for the Pi2.&lt;/p&gt;
&lt;h2&gt;Where I got the idea to try out Retropie&lt;/h2&gt;
&lt;p&gt;One day at lunch break at work, I was talking to my
colleagues about
having a Nintendo as a kid, and remembering playing
a tank game.&lt;/p&gt;
&lt;p&gt;Turns out they also remember playing this game,
but nobody could recall what is was called.&lt;/p&gt;
&lt;p&gt;I had talked about this game to some other people
for more than years, but nobody knew the name of
this game.&lt;/p&gt;
&lt;p&gt;So I started searching on Google, and it turns out
my favourite game on Nintento was called
&lt;a href="https://en.wikipedia.org/wiki/Battle_City_(video_game)"&gt;Battle City&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I found it funny enough, that it took me about 2
minutes of effort to find something I was looking
for about 10-20 years.&lt;/p&gt;
&lt;p&gt;I found a Nintento NES emulator called Nesoid
for Android on Fdroid, however the last uploaded
version is years old.&lt;/p&gt;
&lt;p&gt;However, it still ran on Android 9/Miui 11.
I must say that a touch screen is no way to play
any NES games.&lt;/p&gt;
&lt;h2&gt;Retro games on modern Raspberry Pi 2b&lt;/h2&gt;
&lt;p&gt;So the following day, I burned &lt;a href="https://retropie.org.uk/download/"&gt;Retropie 4.5.1&lt;/a&gt;
to an SD card and slot it into the Pi 2.&lt;/p&gt;
&lt;p&gt;The following example with dd should work, when replacing of=/dev/sdx with
the correct hard drive location.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;dd&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;if&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;/Downloads/retropie-4.5.1-rpi2_rpi3.img&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;of&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/dev/SDZXXZZX&lt;span class="p"&gt;;&lt;/span&gt;sync
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;My old pi booted up and I manually started messing with
Retropie's Emulation Station.&lt;/p&gt;
&lt;p&gt;Since I never used Emulaton Station/Retropie, the
interface was kind of strange at first.&lt;/p&gt;
&lt;p&gt;I also don't have any controllers, so for the time being I'm
setup with a keyboard.&lt;/p&gt;
&lt;p&gt;I configured WASD for up, left, down and right.&lt;/p&gt;
&lt;p&gt;Then right arrow for A and down arrow for B.&lt;/p&gt;
&lt;p&gt;F for start, and G for select.&lt;/p&gt;
&lt;h2&gt;Game ROMs&lt;/h2&gt;
&lt;p&gt;Well, this is an interesting topic, and I'm sure
people will have their own sources to get game ROMs from.&lt;/p&gt;
&lt;p&gt;Some links to note:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://retropie.org.uk/forum/"&gt;Retropie forums&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://old.reddit.com/r/RetroPie/"&gt;Retropiesubreddit&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/retropie/retropie-setup/wiki"&gt;Retropie Github wiki&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/retropie/retropie-setup/wiki/First-Installation"&gt;Retropie First Install guide&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.retrogameboards.com/t/the-ripping-thread-how-to-build-your-own-legit-retro-rom-library/98"&gt;The Ripping Thread - How to build your own legit retro ROM library.&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://web.archive.org/web/20191211212548/https://www.retrogameboards.com/t/the-ripping-thread-how-to-build-your-own-legit-retro-rom-library/98/1"&gt;archive.org link of the above thread&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://retropie.org.uk/forum/topic/10918/where-to-legally-acquire-content-to-play-on-retropie"&gt;Where to (legally) acquire content to play on RetroPie&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;My setup with Retropie&lt;/h3&gt;
&lt;p&gt;Here are the items I have for my Retropie:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Raspberry pi 2b&lt;/li&gt;
&lt;li&gt;8GB Sd card&lt;/li&gt;
&lt;li&gt;RTL8188CUS 802.11n WLAN Adapter&lt;/li&gt;
&lt;li&gt;USB keyboard&lt;/li&gt;
&lt;li&gt;Monitor with HDMI/VGA converter&lt;/li&gt;
&lt;li&gt;5v@2.1A micro-usb charger&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Most of these things can be bought on Amazon/Asda/B&amp;amp;M/Ebay.&lt;/p&gt;
&lt;p&gt;What's interesting is the free memory reported on the Pi
is ~750MB and I thought it had 1GB memory.&lt;/p&gt;
&lt;p&gt;Then I found this page on &lt;a href="https://github.com/RetroPie/RetroPie-Setup/wiki/Memory-Split"&gt;the Github wiki&lt;/a&gt;
, which explains why.&lt;/p&gt;
&lt;h3&gt;Using Ansible on Retropie&lt;/h3&gt;
&lt;p&gt;Since Retropie's just lots of packages on top of Raspbian
Stretch, it means I could run Ansible against it.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Putting Windows 10 on UEFI bootable USB</title><link href="windows-uefi-usb-boot.html" rel="alternate"></link><published>2019-12-02T19:00:00+00:00</published><updated>2019-12-02T19:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-12-02:windows-uefi-usb-boot.html</id><summary type="html">&lt;h1&gt;Windows 10 on hardware&lt;/h1&gt;
&lt;p&gt;I need Windows 10 today to try to root my Xiaomi Android
phone, but first I have to unlock the bootloader,
which is the most annoying process
I have ever been through.&lt;/p&gt;
&lt;p&gt;I tried many programs found on XDA-developers or
/r/xiaomi, but none of them …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Windows 10 on hardware&lt;/h1&gt;
&lt;p&gt;I need Windows 10 today to try to root my Xiaomi Android
phone, but first I have to unlock the bootloader,
which is the most annoying process
I have ever been through.&lt;/p&gt;
&lt;p&gt;I tried many programs found on XDA-developers or
/r/xiaomi, but none of them seem to work.&lt;/p&gt;
&lt;p&gt;I also tried to do USB passthrough my phone to a
Windows vm, but that didn't work out.&lt;/p&gt;
&lt;p&gt;I've got no choice, but to try Xiaomi's own
software to do the unlocking.&lt;/p&gt;
&lt;h2&gt;What's needed for old school USB booting&lt;/h2&gt;
&lt;p&gt;Format the USB drive with GPT partitioning.&lt;/p&gt;
&lt;p&gt;On Debian, there's gparted which makes this easy.&lt;/p&gt;
&lt;p&gt;Once the USB drive is selected, select:&lt;/p&gt;
&lt;p&gt;Device/Create Partition Table/gpt from
"Select new partition table type" then
apply.&lt;/p&gt;
&lt;p&gt;From there, create a new fat32 partition.&lt;/p&gt;
&lt;p&gt;With my USB drive, I let the fat32 to use 100%
of the drive's space.&lt;/p&gt;
&lt;p&gt;Then find the Windows ISO, mount it locally, and
copy all contents to the USB drive's
folder.&lt;/p&gt;
&lt;p&gt;On the target machine, set BOOT mode to
UEFI native(not hybrid).&lt;/p&gt;
&lt;h3&gt;Test it if it works&lt;/h3&gt;
&lt;p&gt;It did! The laptop booted nicely,
and the installation worked great.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Putting old Raspberry Pis to good use</title><link href="old-pi.html" rel="alternate"></link><published>2019-11-29T02:00:00+00:00</published><updated>2019-11-29T02:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-11-29:old-pi.html</id><summary type="html">&lt;h1&gt;Update to this post&lt;/h1&gt;
&lt;p&gt;I put my Raspberry Pi2 to use by installing
&lt;a href="../retropie.html"&gt;Retropie on a functioning SD card&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The issues I mention below were most likely due to
failing/corrupt sd cards.&lt;/p&gt;
&lt;h2&gt;Why use a Raspberry pi at all?&lt;/h2&gt;
&lt;p&gt;They're great devices for learning a different operating system
when …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Update to this post&lt;/h1&gt;
&lt;p&gt;I put my Raspberry Pi2 to use by installing
&lt;a href="../retropie.html"&gt;Retropie on a functioning SD card&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The issues I mention below were most likely due to
failing/corrupt sd cards.&lt;/p&gt;
&lt;h2&gt;Why use a Raspberry pi at all?&lt;/h2&gt;
&lt;p&gt;They're great devices for learning a different operating system
when all one is used to are either Windows or Apple's Osx.&lt;/p&gt;
&lt;p&gt;I got my first pi in 2015, a pi 2b.&lt;/p&gt;
&lt;p&gt;My main machine was an Acer laptop at the time running
Windows 7.&lt;/p&gt;
&lt;p&gt;I remember using putty and Win32 Disk Imager(had to
look this name up)
to write the Raspbian Wheezy image to the sd card I had
at the time.&lt;/p&gt;
&lt;p&gt;They're also great to experiment on, install this,
enter this shell(bash, python) or whatever.&lt;/p&gt;
&lt;p&gt;If you mess up the OS, you can always just write a new
Raspbian image to the card and restart.&lt;/p&gt;
&lt;h2&gt;Times change&lt;/h2&gt;
&lt;p&gt;Over time, I moved to Debian on my acer laptop and
started using Debian Jessie on it.&lt;/p&gt;
&lt;p&gt;Then in 2016, I got a desktop and ran Debian Sid for
a while. Then testing, and stable when Stretch got
released in 2017.&lt;/p&gt;
&lt;p&gt;Kernel 4.9+ was really required to run the AMD polaris cards
I bought in late 2016 and early 2017(rx 460+480).&lt;/p&gt;
&lt;p&gt;After using the Pi2b+ for a while, I got a second Pi3b,
also running Raspbian.&lt;/p&gt;
&lt;p&gt;They ran a couple of things for me in my lan between 2015 -
early 2019, running Squid, Nginx, Dokuwiki, Dnsmasq and
a couple other things I can't remember.&lt;/p&gt;
&lt;p&gt;I was really satisfied with both Pis, however I was dumb
enough to buy the starter kits for both on Amazon.&lt;/p&gt;
&lt;p&gt;I ended up spending a lot more money than I should have.&lt;/p&gt;
&lt;p&gt;Also turns out the Sandisk Ultra sd cards I got were
not so ultra great after all.&lt;/p&gt;
&lt;h2&gt;Putting them to good use again in late 2019&lt;/h2&gt;
&lt;p&gt;Because it's black friday tomorrow, I've been thinking about
buying stuff that I would end up regretting anyway.&lt;/p&gt;
&lt;p&gt;Then it occurred to me, why not use something that I already have.&lt;/p&gt;
&lt;p&gt;I already have 4 Intel machines on my Lan doing various
things, but I have nothing to monitor them.&lt;/p&gt;
&lt;p&gt;So I thought, using one or both of the Pis
could be used for something great.&lt;/p&gt;
&lt;h3&gt;Rummaging through boxes and cables&lt;/h3&gt;
&lt;p&gt;To get the 2 Pis working again, I'd need:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;2 ethernet cables&lt;/li&gt;
&lt;li&gt;2 micro-usb power cables(5v@2.5A are recommended)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I had no issues with getting ethernet cables, I've got plenty of them.&lt;/p&gt;
&lt;p&gt;However, I was having problems with finding power cables that are
good enough for the Pis.&lt;/p&gt;
&lt;p&gt;Reading around on various forums, &lt;a href="https://thepihut.com/blogs/raspberry-pi-tutorials/how-do-i-power-my-raspberry-pi"&gt;sites&lt;/a&gt;
and &lt;a href="https://www.raspberrypi.org/documentation/hardware/raspberrypi/power/README.md"&gt;raspberrypi.org&lt;/a&gt;,
it seems people recommend using a power cable that supplies 5v@2.5A.&lt;/p&gt;
&lt;p&gt;I found one of the PSU that with one of those starter packs, and
it was rated 5.0v@2.0A(Vilros AC adapter, model:
XHY050200LBCW).&lt;/p&gt;
&lt;p&gt;The second PSU I've got that would be good for a Pi is my phone charger.&lt;/p&gt;
&lt;p&gt;So temporarily, I powered up both Pis, started them both with Raspbian
Buster.&lt;/p&gt;
&lt;p&gt;My Pi3 works fine with Buster and I'll be using to monitor
my other machines.&lt;/p&gt;
&lt;p&gt;My Pi2 had several issues.&lt;/p&gt;
&lt;p&gt;With two SD cards, load average would spike to 10-12 while doing a
apt-get update &amp;amp; upgrade combo.&lt;/p&gt;
&lt;p&gt;On the third card, on first boot it would fail to resize the second partition
on the sd card.&lt;/p&gt;
&lt;p&gt;On the second boot with the third card,
I ran raspi-config to try to resize the
partition, however it would also fail.&lt;/p&gt;
&lt;p&gt;It would error out, citing a syntax error on line 151.&lt;/p&gt;
&lt;p&gt;Since raspi-config is a bash script(2048 lines on buster), I had a look with nano:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;nano&lt;span class="w"&gt; &lt;/span&gt;-l&lt;span class="w"&gt; &lt;/span&gt;/usr/bin/raspi-config
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;-l shows the lines with nano.&lt;/p&gt;
&lt;p&gt;The relevant section from raspi-config:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;150&lt;/span&gt;&lt;span class="w"&gt;   &lt;/span&gt;&lt;span class="nv"&gt;LAST_PART_NUM&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="k"&gt;$(&lt;/span&gt;parted&lt;span class="w"&gt; &lt;/span&gt;/dev/mmcblk0&lt;span class="w"&gt; &lt;/span&gt;-ms&lt;span class="w"&gt; &lt;/span&gt;unit&lt;span class="w"&gt; &lt;/span&gt;s&lt;span class="w"&gt; &lt;/span&gt;p&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;tail&lt;span class="w"&gt; &lt;/span&gt;-n&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;cut&lt;span class="w"&gt; &lt;/span&gt;-f&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-d:&lt;span class="k"&gt;)&lt;/span&gt;
&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;151&lt;/span&gt;&lt;span class="w"&gt;   &lt;/span&gt;&lt;span class="k"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$LAST_PART_NUM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-ne&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$PART_NUM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;then&lt;/span&gt;
&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;152&lt;/span&gt;&lt;span class="w"&gt;     &lt;/span&gt;whiptail&lt;span class="w"&gt; &lt;/span&gt;--msgbox&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;quot;&lt;/span&gt;&lt;span class="nv"&gt;$ROOT_PART&lt;/span&gt;&lt;span class="s2"&gt; is not the last partition. Don&amp;#39;t know how to expand&amp;quot;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;20&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;60&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;2&lt;/span&gt;
&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;153&lt;/span&gt;&lt;span class="w"&gt;     &lt;/span&gt;&lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;
&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;154&lt;/span&gt;&lt;span class="w"&gt;   &lt;/span&gt;&lt;span class="k"&gt;fi&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;By looking at this part of the script, I tried to manually run the shell that defined $LAST_PART_NUM.&lt;/p&gt;
&lt;p&gt;So when running:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;parted&lt;span class="w"&gt; &lt;/span&gt;/dev/mmcblk0&lt;span class="w"&gt; &lt;/span&gt;-ms&lt;span class="w"&gt; &lt;/span&gt;unit&lt;span class="w"&gt; &lt;/span&gt;s&lt;span class="w"&gt; &lt;/span&gt;p&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;tail&lt;span class="w"&gt; &lt;/span&gt;-n&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;cut&lt;span class="w"&gt; &lt;/span&gt;-f&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-d:
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I would end up getting segmentation faults with parted every time.&lt;/p&gt;
&lt;p&gt;There would also be some other issues with the Pi2 that I just
ended up shelving it.&lt;/p&gt;
&lt;h2&gt;To-do for Pi3&lt;/h2&gt;
&lt;p&gt;What I've already done:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;erase the pi user&lt;/li&gt;
&lt;li&gt;setup my user&lt;/li&gt;
&lt;li&gt;disable root password and ssh login&lt;/li&gt;
&lt;li&gt;ran my ansible playbook against the pi3&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Figure out what monitoring tool to use.&lt;/p&gt;
&lt;p&gt;I'll probably try out librenms or zabbix.&lt;/p&gt;
&lt;p&gt;If I end up with librenms, I'll have to add snmp to my machines and set up
snmp communities, probably with v3.&lt;/p&gt;
&lt;p&gt;If zabbix wins, then all my other nodes will get zabbix agents.&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Trying out old CentOS images</title><link href="old-centos.html" rel="alternate"></link><published>2019-11-24T02:00:00+00:00</published><updated>2019-11-24T02:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-11-24:old-centos.html</id><summary type="html">&lt;h1&gt;Trying out the oldest available CentOS images&lt;/h1&gt;
&lt;p&gt;I use Debian all the time, however I also like &lt;a href="https://centos.org"&gt;CentOS&lt;/a&gt; for a couple of reasons.&lt;/p&gt;
&lt;p&gt;It's nice that Yum/DNF has transaction history and the ability to undo/redo a certain
installation/removal of packages.&lt;/p&gt;
&lt;p&gt;What is however great is the longer …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Trying out the oldest available CentOS images&lt;/h1&gt;
&lt;p&gt;I use Debian all the time, however I also like &lt;a href="https://centos.org"&gt;CentOS&lt;/a&gt; for a couple of reasons.&lt;/p&gt;
&lt;p&gt;It's nice that Yum/DNF has transaction history and the ability to undo/redo a certain
installation/removal of packages.&lt;/p&gt;
&lt;p&gt;What is however great is the longer(~10 years) supported life time of a release, compared to
Debian's 3-5 years.&lt;/p&gt;
&lt;h2&gt;CentOS 2.1&lt;/h2&gt;
&lt;p&gt;This is the first release I could get my hands on.&lt;/p&gt;
&lt;p&gt;From the &lt;a href="http://vault.centos.org"&gt;CentOS vault&lt;/a&gt;, I had tried to download the ISO files to no avail.&lt;/p&gt;
&lt;p&gt;However, these mirrors are linked from the &lt;a href="http://vault.centos.org/2.1/final/isos/"&gt;2.1 download page&lt;/a&gt;:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="n"&gt;USA&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;
&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;archive&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;kernel&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;org&lt;/span&gt;&lt;span class="sr"&gt;/centos-vault/&lt;/span&gt;
&lt;span class="n"&gt;rsync&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;archive&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;kernel&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;org&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="n"&gt;centos&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;vault&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;

&lt;span class="n"&gt;Europe&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;
&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;mirror&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;nsc&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;liu&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;se&lt;/span&gt;&lt;span class="sr"&gt;/centos-store/&lt;/span&gt;
&lt;span class="n"&gt;rsync&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;mirror&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;nsc&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;liu&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;se&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="n"&gt;centos&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;store&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;

&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;linuxsoft&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;cern&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;ch&lt;/span&gt;&lt;span class="sr"&gt;/centos-vault/&lt;/span&gt;
&lt;span class="n"&gt;rsync&lt;/span&gt;&lt;span class="o"&gt;://&lt;/span&gt;&lt;span class="n"&gt;linuxsoft&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;cern&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="na"&gt;ch&lt;/span&gt;&lt;span class="sr"&gt;/centos-vault/&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I actually used the &lt;a href="http://mirror.nsc.liu.se/centos-store/2.1/final/isos/"&gt;nsc.liu.se&lt;/a&gt; links from above.&lt;/p&gt;
&lt;p&gt;Both disc1 and disc2 images are needed for the installation to complete.&lt;/p&gt;
&lt;p&gt;I also pulled down the MD5SUMS file to check the ISO-s I got were OK.&lt;/p&gt;
&lt;h3&gt;CentOS 2.1 on KVM with virt-manager&lt;/h3&gt;
&lt;p&gt;I've started a local install with disc1.&lt;/p&gt;
&lt;p&gt;Then in the OS type field entered linux, the field "Include EOL OS-s" were already ticked.&lt;/p&gt;
&lt;p&gt;From there, all I had to was find RHEL 2.1.&lt;/p&gt;
&lt;p&gt;Selecting RHEL 2.1 will bring up some default settings which worked OK for this test VM.&lt;/p&gt;
&lt;p&gt;The defaults for the disk &amp;amp; cd bus were ide and the network adapter model defaulted to e1000e.&lt;/p&gt;
&lt;p&gt;The installation was fairly straight-forward, however using the mouse inside the console was finicky,
I ended up using the keyboard(space, tab and enter are great here) instead.&lt;/p&gt;
&lt;p&gt;While installing the packages, the installer asked for disk2.&lt;/p&gt;
&lt;p&gt;I forgot to add a second disk drive before starting the installer, so what I did
was swap the ISO file to disc2 from virt-manager's "Show virtual hardware details" section.&lt;/p&gt;
&lt;p&gt;Then the installer carried finished and all that was left to reboot the VM.&lt;/p&gt;
&lt;h3&gt;Connecting to CentOS 2.1&lt;/h3&gt;
&lt;p&gt;By default the Debian ssh client couldn't connect to SSH 3.1 on C2.1.&lt;/p&gt;
&lt;p&gt;The following command let me connect:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;ssh&lt;span class="w"&gt; &lt;/span&gt;-c&lt;span class="w"&gt; &lt;/span&gt;aes128-cbc&lt;span class="w"&gt; &lt;/span&gt;-oKexAlgorithms&lt;span class="o"&gt;=&lt;/span&gt;+diffie-hellman-group1-sha1&lt;span class="w"&gt; &lt;/span&gt;root@192.168.122.16
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I tried using ssh-copy-id for C2.1, but only using ~/.ssh/config as a workaround I managed
to get this working. Relevant ssh-config snippet:&lt;/p&gt;
&lt;pre&gt;
Host c2
    Hostname 192.168.122.16
    User root
    Port 22
    Identityfile ~/.ssh/id_rsa
    Ciphers aes192-cbc
    KexAlgorithms=+diffie-hellman-group1-sha1
&lt;/pre&gt;

&lt;p&gt;Then all it was just ssh-copy-id c2 and enter the password.&lt;/p&gt;
&lt;p&gt;To enable the use of yum, I had to swap the repos in /etc/yum.conf to the mirror
where I got the iso from.&lt;/p&gt;
&lt;p&gt;In my case, /etc/yum.conf looks like the following:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="n"&gt;root@localhost root&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="err"&gt;#&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;cat&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;etc&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;yum&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;conf&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="n"&gt;main&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="n"&gt;cachedir&lt;/span&gt;&lt;span class="o"&gt;=/&lt;/span&gt;&lt;span class="nf"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;cache&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;yum&lt;/span&gt;
&lt;span class="n"&gt;debuglevel&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;
&lt;span class="n"&gt;logfile&lt;/span&gt;&lt;span class="o"&gt;=/&lt;/span&gt;&lt;span class="nf"&gt;var&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;yum&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;
&lt;span class="n"&gt;pkgpolicy&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;newest&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="n"&gt;base&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;CentOS&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;base&lt;/span&gt;
&lt;span class="n"&gt;baseurl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nl"&gt;http&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;mirror&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;nsc&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;liu&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;se&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;centos&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;store&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="mf"&gt;2.1&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;i386&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;CentOS&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="n"&gt;updates&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;CentOS&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;updates&lt;/span&gt;
&lt;span class="n"&gt;baseurl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nl"&gt;http&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;mirror&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;nsc&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;liu&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;se&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;centos&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;store&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="mf"&gt;2.1&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;updates&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="n"&gt;extras&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;CentOS&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;extras&lt;/span&gt;
&lt;span class="n"&gt;baseurl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nl"&gt;http&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;mirror&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;nsc&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;liu&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;se&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;centos&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;store&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="mf"&gt;2.1&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;extras&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;This let me update all the packages on the system to latest.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;root&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# yum -y update&lt;/span&gt;
Gathering&lt;span class="w"&gt; &lt;/span&gt;package&lt;span class="w"&gt; &lt;/span&gt;information&lt;span class="w"&gt; &lt;/span&gt;from&lt;span class="w"&gt; &lt;/span&gt;servers
Getting&lt;span class="w"&gt; &lt;/span&gt;headers&lt;span class="w"&gt; &lt;/span&gt;from:&lt;span class="w"&gt; &lt;/span&gt;CentOS-2&lt;span class="w"&gt; &lt;/span&gt;base
Getting&lt;span class="w"&gt; &lt;/span&gt;headers&lt;span class="w"&gt; &lt;/span&gt;from:&lt;span class="w"&gt; &lt;/span&gt;CentOS-2&lt;span class="w"&gt; &lt;/span&gt;extras
Getting&lt;span class="w"&gt; &lt;/span&gt;headers&lt;span class="w"&gt; &lt;/span&gt;from:&lt;span class="w"&gt; &lt;/span&gt;CentOS-2&lt;span class="w"&gt; &lt;/span&gt;updates
Finding&lt;span class="w"&gt; &lt;/span&gt;updated&lt;span class="w"&gt; &lt;/span&gt;packages
Downloading&lt;span class="w"&gt; &lt;/span&gt;needed&lt;span class="w"&gt; &lt;/span&gt;headers
No&lt;span class="w"&gt; &lt;/span&gt;Packages&lt;span class="w"&gt; &lt;/span&gt;Available&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;for&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;Update
No&lt;span class="w"&gt; &lt;/span&gt;actions&lt;span class="w"&gt; &lt;/span&gt;to&lt;span class="w"&gt; &lt;/span&gt;take
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Now my Centos 2.1 VM is so secure!&lt;/p&gt;
&lt;p&gt;Now let's enable and start httpd, because what could go wrong?&lt;/p&gt;
&lt;p&gt;What's interesting is that the package used to be called apache,
but the service was already called httpd like it is nowadays.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;root&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# service httpd start&lt;/span&gt;
Starting&lt;span class="w"&gt; &lt;/span&gt;httpd:&lt;span class="w"&gt;                                            &lt;/span&gt;&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;OK&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;root&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# chkconfig httpd on&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;root&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# chkconfig --list httpd&lt;/span&gt;
httpd&lt;span class="w"&gt;           &lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;:off&lt;span class="w"&gt;   &lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;:off&lt;span class="w"&gt;   &lt;/span&gt;&lt;span class="m"&gt;2&lt;/span&gt;:on&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="m"&gt;3&lt;/span&gt;:on&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="m"&gt;4&lt;/span&gt;:on&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="m"&gt;5&lt;/span&gt;:on&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="m"&gt;6&lt;/span&gt;:off
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;root&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# httpd -v&lt;/span&gt;
Server&lt;span class="w"&gt; &lt;/span&gt;version:&lt;span class="w"&gt; &lt;/span&gt;Apache/1.3.27&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;Unix&lt;span class="o"&gt;)&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;Red-Hat/Linux&lt;span class="o"&gt;)&lt;/span&gt;
Server&lt;span class="w"&gt; &lt;/span&gt;built:&lt;span class="w"&gt;   &lt;/span&gt;Jan&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;16&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;2008&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;12&lt;/span&gt;:08:50
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Here are some screenshots:&lt;/p&gt;
&lt;p&gt;&lt;img alt="rhel 2.1 selection from virt-manager" src="photos/2019-11-24-01-40-40_506x532a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="press enter to boot the installer" src="photos/2019-11-24-01-44-36_825x632a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="installer booting" src="photos/2019-11-24-01-44-47_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="starting the package installer" src="photos/2019-11-24-00-58-12_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="install in progress" src="photos/2019-11-24-01-00-11_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="install finished" src="photos/2019-11-24-01-00-35_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="old grub screen" src="photos/2019-11-24-01-00-52_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="old boot process" src="photos/2019-11-24-01-00-58_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="apache 1.3.27" src="photos/screenshot_2019-11-24_03-07-41a.jpg"&gt;&lt;/p&gt;
&lt;h2&gt;Centos 3.9&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://en.wikipedia.org/wiki/Centos#Older_version_information"&gt;Centos 3&lt;/a&gt; originally was released in 2004/03/19 as 3.1.&lt;/p&gt;
&lt;p&gt;I grabbed both i386 and amd64 versions of 3.9 from the &lt;a href="http://mirror.nsc.liu.se/centos-store/3.9/isos/"&gt;liu.se mirror&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The installation was a bit simpler than doing Centos 2.&lt;/p&gt;
&lt;p&gt;To connect with SSH, I've set the following settings in ~/.ssh/config, which is a lot similar to what I have for c2:&lt;/p&gt;
&lt;pre&gt;
Host c3
        Hostname 192.168.122.137
        User root
        Port 22
        Identityfile ~/.ssh/id_rsa
        Ciphers aes256-cbc
        KexAlgorithms=+diffie-hellman-group1-sha1
&lt;/pre&gt;

&lt;p&gt;Afterwards, I add my SSH keys to my C3 vm with ssh-copy-id and I'm in!&lt;/p&gt;
&lt;p&gt;There were 4 commands required to setup yum to work properly today.&lt;/p&gt;
&lt;p&gt;First making a backup of /etc/yum.conf. This is just optional.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;cp&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.conf&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Second changing the repo urls in /etc/yum.conf to the mirror I use.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;sed&lt;span class="w"&gt; &lt;/span&gt;-i&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;s#mirror.centos.org/centos#mirror.nsc.liu.se/centos-store#g&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.conf

sed&lt;span class="w"&gt; &lt;/span&gt;-i&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;s#$releasever#3.9#g&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.conf
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I was surprised to see '#' to work for gnu sed 4.0.7.&lt;/p&gt;
&lt;p&gt;Last, yum was missing a gpg key
(warning: rpmts_HdrFromFdno: V3 DSA signature: NOKEY, key ID 025e513b),
which has to be imported:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;rpm&lt;span class="w"&gt; &lt;/span&gt;--import&lt;span class="w"&gt; &lt;/span&gt;http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-3
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;I also tried getting httpd working on 3.9, here's how it went.&lt;/p&gt;
&lt;p&gt;First, the package name has changed to httpd instead of apache.&lt;/p&gt;
&lt;p&gt;The service and chkconfig commands are the same as for 2.1.&lt;/p&gt;
&lt;p&gt;Also, apache was at version 2.0 at this time.&lt;/p&gt;
&lt;p&gt;However, for this VM, I forgot to add http for to be allowed
during installation, so had to update the firewall:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;iptables&lt;span class="w"&gt; &lt;/span&gt;-A&lt;span class="w"&gt; &lt;/span&gt;INPUT&lt;span class="w"&gt; &lt;/span&gt;-p&lt;span class="w"&gt; &lt;/span&gt;tcp&lt;span class="w"&gt; &lt;/span&gt;--dport&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;80&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-m&lt;span class="w"&gt; &lt;/span&gt;conntrack&lt;span class="w"&gt; &lt;/span&gt;--ctstate&lt;span class="w"&gt; &lt;/span&gt;NEW,ESTABLISHED&lt;span class="w"&gt; &lt;/span&gt;-j&lt;span class="w"&gt; &lt;/span&gt;ACCEPT
iptables&lt;span class="w"&gt; &lt;/span&gt;-A&lt;span class="w"&gt; &lt;/span&gt;INPUT&lt;span class="w"&gt; &lt;/span&gt;-p&lt;span class="w"&gt; &lt;/span&gt;tcp&lt;span class="w"&gt; &lt;/span&gt;--dport&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;443&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-m&lt;span class="w"&gt; &lt;/span&gt;conntrack&lt;span class="w"&gt; &lt;/span&gt;--ctstate&lt;span class="w"&gt; &lt;/span&gt;NEW,ESTABLISHED&lt;span class="w"&gt; &lt;/span&gt;-j&lt;span class="w"&gt; &lt;/span&gt;ACCEPT
service&lt;span class="w"&gt; &lt;/span&gt;iptables&lt;span class="w"&gt; &lt;/span&gt;save
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Compared to Centos 2, v3 didn't require a second cd to finish the
installation.&lt;/p&gt;
&lt;p&gt;A couple screenshots for Centos 3:&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 3 linux mascot" src="photos/2019-11-24-02-58-35_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 3 install complete" src="photos/2019-11-24-02-59-07_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 3 console" src="photos/2019-11-24-03-10-22_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="apache 2.0 on Centos 3.9" src="photos/screenshot_2019-11-24_03-45-19a.jpg"&gt;&lt;/p&gt;
&lt;h2&gt;Centos 4&lt;/h2&gt;
&lt;p&gt;Using the 4.9 installation media, the installer process is
better than that of 3.&lt;/p&gt;
&lt;p&gt;To install C4, the first ISO("CentOS-4.8-x86_64-bin1of5.iso") was enough.&lt;/p&gt;
&lt;p&gt;A couple lines of sed were required to get yum working:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;cp&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.repos.d/CentOS-Base.repo&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="c1"&gt;# uncomment mirror list&lt;/span&gt;
sed&lt;span class="w"&gt; &lt;/span&gt;-i&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;s/mirrorlist=/#mirrorlist=/g&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.repos.d/CentOS-Base.repo
&lt;span class="c1"&gt;# use baseurl instead&lt;/span&gt;
sed&lt;span class="w"&gt; &lt;/span&gt;-i&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;s/#baseurl=/baseurl=/g&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.repos.d/CentOS-Base.repo
&lt;span class="c1"&gt;# change centos mirror to lie.se mirr&lt;/span&gt;
sed&lt;span class="w"&gt; &lt;/span&gt;-i&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;s#mirror.centos.org/centos/$releasever#mirror.nsc.liu.se/centos-store/4.9#g&amp;#39;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;/etc/yum.repos.d/CentOS-Base.repo
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Getting httpd to run was the same process as it was for CentOS 3.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# chkconfig httpd on&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# service httpd start&lt;/span&gt;
Starting&lt;span class="w"&gt; &lt;/span&gt;httpd:&lt;span class="w"&gt;                                            &lt;/span&gt;&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;OK&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;root@localhost&lt;span class="w"&gt; &lt;/span&gt;~&lt;span class="o"&gt;]&lt;/span&gt;&lt;span class="c1"&gt;# httpd -v&lt;/span&gt;
Server&lt;span class="w"&gt; &lt;/span&gt;version:&lt;span class="w"&gt; &lt;/span&gt;Apache/2.0.52
Server&lt;span class="w"&gt; &lt;/span&gt;built:&lt;span class="w"&gt;   &lt;/span&gt;Oct&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;20&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;2011&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;14&lt;/span&gt;:31:42
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Screenshots:&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 installer first screen" src="photos/2019-11-24-09-32-45_825x632a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 installer" src="photos/2019-11-24-09-37-03_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 grub" src="photos/2019-11-24-09-37-50_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 booting" src="photos/2019-11-24-09-38-04_806x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 EOL message" src="photos/2019-11-24-10-09-54_825x699a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Centos 4 httpd welcome page" src="photos/screenshot_2019-11-24_10-22-33a.jpg"&gt;&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Migrating from OVH Pro Email to Gsuite</title><link href="migrating-ovh-email-gsuite.html" rel="alternate"></link><published>2019-11-19T21:00:00+00:00</published><updated>2019-11-19T21:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-11-19:migrating-ovh-email-gsuite.html</id><summary type="html">&lt;h1&gt;Migrating email from one service to another&lt;/h1&gt;
&lt;p&gt;I'm currently working on migrating from &lt;a href="https://www.ovh.co.uk/emails/email-pro/"&gt;OVH's pro email service&lt;/a&gt; to &lt;a href="https://gsuite.google.com/pricing.html"&gt;Gsuite&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Experience with OVH's mail service&lt;/h2&gt;
&lt;p&gt;My monthly cost with OVH's service has been £2.49 since last year.&lt;/p&gt;
&lt;p&gt;I've started using Mail Pro since end of September last year.&lt;/p&gt;
&lt;p&gt;From my …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Migrating email from one service to another&lt;/h1&gt;
&lt;p&gt;I'm currently working on migrating from &lt;a href="https://www.ovh.co.uk/emails/email-pro/"&gt;OVH's pro email service&lt;/a&gt; to &lt;a href="https://gsuite.google.com/pricing.html"&gt;Gsuite&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Experience with OVH's mail service&lt;/h2&gt;
&lt;p&gt;My monthly cost with OVH's service has been £2.49 since last year.&lt;/p&gt;
&lt;p&gt;I've started using Mail Pro since end of September last year.&lt;/p&gt;
&lt;p&gt;From my experience, it has been very reliable, however I've been having email delivery issues to Microsoft and Gmail email addresses.&lt;/p&gt;
&lt;p&gt;Also, I couldn't find a way to setup DKIM/DMARC with this service.&lt;/p&gt;
&lt;p&gt;However, I've had the following SPF record, but I'm not sure how much it helped with email delivery rates.&lt;/p&gt;
&lt;pre&gt;
v=spf1 a mx include:mx.ovh.com -all
&lt;/pre&gt;

&lt;h2&gt;My reasons to migrating to Google Gsuite&lt;/h2&gt;
&lt;p&gt;Well, email delivery is the biggest one.&lt;/p&gt;
&lt;p&gt;I rarely send emails but I got the feeling over the past year that people haven't been receiving/reading them.&lt;/p&gt;
&lt;p&gt;Second, I believe I can setup DKIM/DMARC records so this will help with email delivery.&lt;/p&gt;
&lt;p&gt;Third, is having access to Gsuite's presumably unlimited Google drive service, even with one user. Who knows
how long this will last.&lt;/p&gt;
&lt;p&gt;Fourth, I'd like to try something new.&lt;/p&gt;
&lt;p&gt;Fifth, it's the experience with Gsuite. I've seen people mentioning on different IT news sites/forums of using
Gsuite. By using it personally, I might gain valuable experience in a future role.&lt;/p&gt;
&lt;p&gt;The only two downsides I can think of are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;increased monthly costs&lt;/li&gt;
&lt;li&gt;hosting personal email with Google&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Migration experience for a personal/single user domain&lt;/h2&gt;
&lt;p&gt;First, I had to add a txt record to my DNS zone at Cloudflare to prove
ownership of my domain.&lt;/p&gt;
&lt;p&gt;After, I've done that, I had to start adding users. The 14 days trial period allows I believe
adding 10 users if needed for testing.&lt;/p&gt;
&lt;p&gt;Since it was just for me, I've already had my user setup.&lt;/p&gt;
&lt;p&gt;I had a gotcha here however.&lt;/p&gt;
&lt;p&gt;I've got a different Google account with my primary email address which is for
testing Google Cloud's trial year with the $300 credit(~£226 at the time).&lt;/p&gt;
&lt;p&gt;Since my email was already in use in Google's system,
I had to use another email for the initial account creation with Gsuite.&lt;/p&gt;
&lt;p&gt;So instead of my old/regular email of whatever@domain.tld, I had to use whatever1@domain.tld.&lt;/p&gt;
&lt;p&gt;Fortunately, in the &lt;a href="https://admin.google.com/ac/users/abc/profile"&gt;admin panel/user settings&lt;/a&gt;
I could setup email aliases, so my old address will be an alias of my new address.&lt;/p&gt;
&lt;p&gt;I'm still exploring the admin control panel, so that will some take time getting used to.&lt;/p&gt;
&lt;h3&gt;Imap on Gmail&lt;/h3&gt;
&lt;p&gt;I use Thunderbird(TB) 68.x on Debian 10, so I need IMAP access to my email address.&lt;/p&gt;
&lt;p&gt;I had to turn on IMAP access for the domain, as per &lt;a href="https://support.google.com/a/answer/105694"&gt;kb105694&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Then enable IMAP access for "less secure devices" in Gmail.&lt;/p&gt;
&lt;p&gt;I added a "New account" in Thunderbird, with the Gmail imap and smtp records.&lt;/p&gt;
&lt;p&gt;Then TB opened up a new window with a Google Oauth page asking me
to grant Thunderbird access to my Gmail account, which I did.&lt;/p&gt;
&lt;p&gt;&lt;img alt="thunderbird-gmail" src="photos/2019-11-19-20-58-46_1920x1049a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;Before migrating emails over, I kept my old email address at OVH in TB.&lt;/p&gt;
&lt;p&gt;Made 3 local folders for backup purposes.&lt;/p&gt;
&lt;p&gt;One for the main inbox, one for sent and for an archived folder.&lt;/p&gt;
&lt;h3&gt;Migrating 5000+ emails&lt;/h3&gt;
&lt;p&gt;I've got over 5000 emails gathered over the last few years.&lt;/p&gt;
&lt;p&gt;The first thing I've tried was trying to copy from local folders to Inbox, Sent and Archived folder
inside Thunderbird itself.&lt;/p&gt;
&lt;p&gt;However, this turned out to be unreliable with Gmail because only a fraction of my emails would be uploaded
to Gmail. I'd get "Connection timed out to imap.gmail.com" error messages.&lt;/p&gt;
&lt;p&gt;Then I've tried the Data Migration wizard inside the Gsuite admin panel, however this turned out to be way too slow.&lt;/p&gt;
&lt;p&gt;I aborted the Migration after around 6%.&lt;/p&gt;
&lt;p&gt;Then I remembered &lt;a href="https://imapsync.lamiral.info/"&gt;Imapsync&lt;/a&gt; from Gilles Lamiral.&lt;/p&gt;
&lt;p&gt;I also remember that he had a docker image up at &lt;a href="https://hub.docker.com/r/gilleslamiral/imapsync/"&gt;gilleslamiral/imapsync&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I've pulled down his image, then ran an instance of it and put into background:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;docker&lt;span class="w"&gt; &lt;/span&gt;run&lt;span class="w"&gt; &lt;/span&gt;--name&lt;span class="w"&gt; &lt;/span&gt;im&lt;span class="w"&gt; &lt;/span&gt;-d&lt;span class="w"&gt; &lt;/span&gt;-t&lt;span class="w"&gt; &lt;/span&gt;--rm&lt;span class="w"&gt; &lt;/span&gt;gilleslamiral/imapsync&lt;span class="w"&gt; &lt;/span&gt;sleep&lt;span class="w"&gt; &lt;/span&gt;infinity
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Then attached into the container called im inside a tmux session:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;docker&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;exec&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-ti&lt;span class="w"&gt; &lt;/span&gt;im&lt;span class="w"&gt; &lt;/span&gt;bash
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Once inside the container, I started the imapsync process with:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;imapsync&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="se"&gt;\&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;--noreleasecheck&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="se"&gt;\&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;--host1&lt;span class="w"&gt; &lt;/span&gt;pro1.mail.ovh.net&lt;span class="w"&gt; &lt;/span&gt;--ssl1&lt;span class="w"&gt; &lt;/span&gt;--port1&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;993&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;--user1&lt;span class="w"&gt; &lt;/span&gt;email@domain.tld&lt;span class="w"&gt; &lt;/span&gt;--password1&lt;span class="w"&gt; &lt;/span&gt;hunter2&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="se"&gt;\&lt;/span&gt;
&lt;span class="w"&gt;    &lt;/span&gt;--gmail2&lt;span class="w"&gt; &lt;/span&gt;--user2&lt;span class="w"&gt; &lt;/span&gt;email1@domain.tld&lt;span class="w"&gt; &lt;/span&gt;--password2&lt;span class="w"&gt; &lt;/span&gt;hunter3
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;This resulted in the following:&lt;/p&gt;
&lt;pre&gt;
Host1: Expunging folder archive_folder
ETA: Tue Nov 19 19:00:33 2019  1 s  1/5799 msgs left
++++ End looping on each folder

Folders sizes after the synchronization.
You can remove this foldersizes listing by using  "--nofoldersizesatend"
...

Host1 Nb folders:                    16 folders
Host2 Nb folders:                    14 folders

Host1 Nb messages:                 5798 messages
Host2 Nb messages:                 5709 messages

Host1 Total size:             289009755 bytes (275.621 MiB)Host2 Total size:             200927369 bytes (191.619 MiB)                                                                                                                           [0/1889]

Host1 Biggest message:         20405072 bytes (19.460 MiB)
Host2 Biggest message:         27913861 bytes (26.621 MiB)

Time spent on sizing:        33.8 seconds
++++ Statistics
Transfer started on                     : Tue Nov 19 17:32:36 2019
Transfer ended on                       : Tue Nov 19 19:01:07 2019
Transfer time                           : 5311.1 sec
Folders synced                          : 16/16 synced
Messages transferred                    : 5705
Messages skipped                        : 92
Messages found duplicate on host1       : 48
Messages found duplicate on host2       : 0
Messages found crossduplicate on host2  : 0
Messages void (noheader) on host1       : 0
Messages void (noheader) on host2       : 0
Messages found in host1 not in host2    : 1 messages
Messages found in host2 not in host1    : 1 messages
Messages deleted on host1               : 0
Messages deleted on host2               : 0
Total bytes transferred                 : 200801589 (191.499 MiB)
Total bytes skipped                     : 13109007 (12.502 MiB)
Message rate                            : 1.1 messages/s
Average bandwidth rate                  : 36.9 KiB/s
Reconnections to host1                  : 0
Reconnections to host2                  : 0
Memory consumption at the end           : 275.2 MiB (started with 218.4 MiB)
Load end is                             : 0.18 0.17 0.21 6/659 on 2 cores
Biggest message                         : 27913861 bytes (26.621 MiB)
Memory/biggest message ratio            : 10.3
Start difference host2 - host1          : -5750 messages, -326607299 bytes (-311.477 MiB)
Final difference host2 - host1          : -89 messages, -88082386 bytes (-84.002 MiB)
The sync is not finished, there are 1 identified messages in host1 that are not on host2.
There is no unidentified message
The sync is not strict, there are 1 messages in host2 that are not on host1. Use --delete2 to delete them and have a strict sync. (5679 identified messages in host2)
Detected 3 errors

Check if a new imapsync release is available by adding --releasecheck
Homepage: https://imapsync.lamiral.info/
++++ Listing 3 errors encountered during the sync ( avoid this listing with --noerrorsdump ).
Err 1/3: Host2 Folder Outbox: Could not select: 31 NO [NONEXISTENT] Unknown Mailbox: Outbox (now in authenticated state) (Failure)
Err 2/3: Host2 Folder archive_folder: Could not select: 38 NO [NONEXISTENT] Unknown Mailbox: archive_folder (now in authenticated state) (Failure)
Err 3/3: - msg INBOX/5329 {23820} could not append ( Subject:[whatever], Date:["15-Oct-2017 12:13:35 +0100"], Size:[34930], Flags:[\Seen] ) t
o folder INBOX: * BYE Invalid character in literal (4x)
Exiting with return value 111 (EXIT_WITH_ERRORS) 3/50 nb_errors/max_errors
&lt;/pre&gt;

&lt;p&gt;Many thanks for Gilles Lamiral for this brilliant tool.&lt;/p&gt;
&lt;h4&gt;Other links that I found useful for Gsuite/Gmail &amp;amp; Imap&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://support.google.com/a/answer/9003945?hl=en"&gt;https://support.google.com/a/answer/9003945?hl=en&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://support.google.com/a/answer/33327?hl=en"&gt;https://support.google.com/a/answer/33327?hl=en&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://support.google.com/a/answer/33786"&gt;Setting up SPF&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://support.google.com/a/answer/174124"&gt;Setting up DKIM&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://admin.google.com/AdminHome?hl=en#AppDetails:service=email&amp;amp;flyout=authenticate_email"&gt;Generate the DKIM key and txt DNS record in Gsuite admin console&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://support.google.com/a/answer/2466563?hl=en&amp;amp;ref_topic=2759254"&gt;Turn on DMARC&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;SPF txt record:&lt;/p&gt;
&lt;pre&gt;
v=spf1 include:_spf.google.com -all
&lt;/pre&gt;

&lt;p&gt;Example DKIM record for a root domain:&lt;/p&gt;
&lt;pre&gt;
DNS Host name (TXT record name):
google._domainkey
TXT record value:
v=DKIM1; k=rsa; p=whatever
&lt;/pre&gt;

&lt;p&gt;Example DMARC record for a root domain:&lt;/p&gt;
&lt;pre&gt;
TXT record name:
_dmarc.domain.tld
TXT record value:
v=DMARC1; p=none; rua=mailto:dmarc@domain.tld
&lt;/pre&gt;

&lt;p&gt;Imap &amp;amp; SMTP details for Gsuite:&lt;/p&gt;
&lt;pre&gt;
Incoming mail settings

Server: imap.gmail.com
Require SSL: Yes
Port: 993

Outgoing mail

Server: smtp.gmail.com
Require SSL: Yes
Require TLS: Yes
Require authentication: Yes
Port for SSL: 465
Port for TLS/STARTTLS: 587
&lt;/pre&gt;

&lt;p&gt;After finally mucking around with the SPF, DKIM and DMARC records for hours, I get passes
on all records at Gmail, Zoho and Outlook. Yay.&lt;/p&gt;
&lt;h3&gt;Example Terraform Code for Cloudflare provider ~v1.x&lt;/h3&gt;
&lt;p&gt;Here's a sample code repo:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://gitlab.com/richardskumat/public-terraform-examples/tree/master/20191121_gsuite_dkim_spf_dmarc_cloudflare"&gt;Gitlab&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/richardskumat/public-terraform-examples/tree/master/20191121_gsuite_dkim_spf_dmarc_cloudflare"&gt;Github&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Google Drive for Rclone&lt;/h3&gt;
&lt;p&gt;I plan on using Gdrive with Rclone with a crypted remote for remote backups to the cloud.&lt;/p&gt;
&lt;p&gt;My current local backup procedure isn't the best, so adding Gdrive to the mix might help
with reorganising my thinking &amp;amp; scripts.&lt;/p&gt;
&lt;p&gt;To-dos:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;write backup scripts&lt;/li&gt;
&lt;li&gt;setup rclone remotes&lt;/li&gt;
&lt;li&gt;decide whether to backup from both my desktop and nas or just from the nas&lt;/li&gt;
&lt;/ul&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Servers and clients in my homelab</title><link href="homelab-devices.html" rel="alternate"></link><published>2019-11-12T12:00:00+00:00</published><updated>2019-11-12T12:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-11-12:homelab-devices.html</id><summary type="html">&lt;h1&gt;My homelab computers&lt;/h1&gt;
&lt;p&gt;I have 4 computers at home that each have their own use.&lt;/p&gt;
&lt;p&gt;I have a desktop that I built in 2016/11 that is my main computer and which I use
the most and code from.&lt;/p&gt;
&lt;p&gt;I also have a HP Probook 6570b which is my laptop …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;My homelab computers&lt;/h1&gt;
&lt;p&gt;I have 4 computers at home that each have their own use.&lt;/p&gt;
&lt;p&gt;I have a desktop that I built in 2016/11 that is my main computer and which I use
the most and code from.&lt;/p&gt;
&lt;p&gt;I also have a HP Probook 6570b which is my laptop, which I take with me on occasions
and watch movies from.&lt;/p&gt;
&lt;p&gt;Then I've got my first laptop, an Acer Aspire 5736z, which only runs Pihole and serves
as the DHCP and DNS server on the network and nothing else.&lt;/p&gt;
&lt;p&gt;And the last device is my HP Proliant Gen8 Microserver that runs
about 5-10 docker images and serves as file server on the network.&lt;/p&gt;
&lt;p&gt;Probably should mention the ISP provided "fantastic high quality"
modem/router that serves as the router and wifi AP at this point in time.&lt;/p&gt;
&lt;p&gt;I've got two Raspberry Pis, a 2b and a 3b+.&lt;/p&gt;
&lt;p&gt;I used to use DNSMasq and Squid proxy on these Pis in my previous place,
but then I realized I already four Intel machines to use.&lt;/p&gt;
&lt;p&gt;In the long term, I'd like to reduce my devices to maybe a desktop and a laptop.&lt;/p&gt;
&lt;p&gt;But for the time being, having only Intel machines(as in having all of them on amd64
operating systems) means simpler Ansible playbooks, roles and Docker images.&lt;/p&gt;
&lt;h2&gt;Network Diagram&lt;/h2&gt;
&lt;p&gt;Here's the homelab network diagram I've made with &lt;a href="../drawio-diagram.html"&gt;draw.io&lt;/a&gt;:&lt;/p&gt;
&lt;p&gt;&lt;a href="../images/20191111_homelab_network.png"&gt;homelab network diagram&lt;/a&gt;&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Playing with draw.io diagrams</title><link href="drawio-diagram.html" rel="alternate"></link><published>2019-11-11T22:00:00+00:00</published><updated>2019-11-11T22:00:00+00:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-11-11:drawio-diagram.html</id><summary type="html">&lt;p&gt;&lt;a href="https://about.draw.io/about-us/"&gt;Draw.io&lt;/a&gt; is nice!&lt;/p&gt;
&lt;p&gt;It's a program that make nice diagrams and so many other things.&lt;/p&gt;
&lt;p&gt;Works OK in a browser, on desktops and it's cross platform.&lt;/p&gt;
&lt;p&gt;I've seen many nice network diagrams on &lt;a href="https://old.reddit.com/r/homelab/"&gt;/r/homelab&lt;/a&gt; and
saw &lt;a href="draw.io"&gt;draw.io&lt;/a&gt; recommended in the comments.&lt;/p&gt;
&lt;h2&gt;Running it locally&lt;/h2&gt;
&lt;p&gt;There's a handy …&lt;/p&gt;</summary><content type="html">&lt;p&gt;&lt;a href="https://about.draw.io/about-us/"&gt;Draw.io&lt;/a&gt; is nice!&lt;/p&gt;
&lt;p&gt;It's a program that make nice diagrams and so many other things.&lt;/p&gt;
&lt;p&gt;Works OK in a browser, on desktops and it's cross platform.&lt;/p&gt;
&lt;p&gt;I've seen many nice network diagrams on &lt;a href="https://old.reddit.com/r/homelab/"&gt;/r/homelab&lt;/a&gt; and
saw &lt;a href="draw.io"&gt;draw.io&lt;/a&gt; recommended in the comments.&lt;/p&gt;
&lt;h2&gt;Running it locally&lt;/h2&gt;
&lt;p&gt;There's a handy docker image at &lt;a href="https://hub.docker.com/r/fjudith/draw.io"&gt;fjudith/draw.io&lt;/a&gt; that I started using.&lt;/p&gt;
&lt;p&gt;I made my homelab network diagram with it, then exported a png image from it.&lt;/p&gt;
&lt;p&gt;A command like this can run it locally, as non-root with user:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;docker&lt;span class="w"&gt; &lt;/span&gt;run&lt;span class="w"&gt; &lt;/span&gt;--user&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;1234&lt;/span&gt;:1234&lt;span class="w"&gt; &lt;/span&gt;--rm&lt;span class="w"&gt; &lt;/span&gt;-d&lt;span class="w"&gt; &lt;/span&gt;--name&lt;span class="o"&gt;=&lt;/span&gt;draw&lt;span class="w"&gt; &lt;/span&gt;-p&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;8080&lt;/span&gt;:8080&lt;span class="w"&gt; &lt;/span&gt;fjudith/draw.io:alpine
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h3&gt;Here's my first diagram&lt;/h3&gt;
&lt;p&gt;This is the first diagram I've made with it:&lt;/p&gt;
&lt;p&gt;&lt;a href="../images/20191111_homelab_network.png"&gt;homelab network diagram&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;More details on this image can be found in this post:&lt;/p&gt;
&lt;p&gt;&lt;a href="../homelab-devices.html"&gt;My home network&lt;/a&gt;&lt;/p&gt;</content><category term="blog"></category><category term="homelab"></category></entry><entry><title>Releasing Dilbert scraper's docker image</title><link href="dilbert-scraper-docker.html" rel="alternate"></link><published>2019-10-18T12:00:00+01:00</published><updated>2019-10-18T12:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-10-18:dilbert-scraper-docker.html</id><summary type="html">&lt;h1&gt;Dilbert.com scraper&lt;/h1&gt;
&lt;p&gt;I wrote a &lt;a href="https://gitlab.com/richardskumat/dilbert"&gt;dilbert.com comics scraper&lt;/a&gt; in bash about 3 years ago because I really love &lt;a href="https://dilbert.com"&gt;Dilbert comics&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;While I assume people will scream if they look at the code in dilbert.sh and date generator python script, they have worked fairly reliably for 3 years …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Dilbert.com scraper&lt;/h1&gt;
&lt;p&gt;I wrote a &lt;a href="https://gitlab.com/richardskumat/dilbert"&gt;dilbert.com comics scraper&lt;/a&gt; in bash about 3 years ago because I really love &lt;a href="https://dilbert.com"&gt;Dilbert comics&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;While I assume people will scream if they look at the code in dilbert.sh and date generator python script, they have worked fairly reliably for 3 years, with the only
breakage that occurred was when dilbert.com changed to https as my parsing code is lame.&lt;/p&gt;
&lt;h2&gt;Put it into a docker image because why not&lt;/h2&gt;
&lt;p&gt;So today also I got a working image up on &lt;a href="https://hub.docker.com/r/qwe1/dilbert"&gt;Dockerhub&lt;/a&gt; and &lt;a href="https://gitlab.com/richardskumat/dilbert/container_registry"&gt;Gitlab's docker registry&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;For usage instructions, please read the &lt;a href="https://gitlab.com/richardskumat/dilbert/blob/master/docker/readme.md"&gt;readme provided on Gitlab&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;As anything I'd write here or on dockerhub would eventually become outdated.&lt;/p&gt;
&lt;p&gt;But to save some clicks, here are two one-liners:&lt;/p&gt;
&lt;p&gt;Here's a sample command to download all comics:&lt;/p&gt;
&lt;pre&gt;
docker run -d --name dilbert --rm -v $HOME/Pictures/dilbert:/home/user/Pictures/dilbert qwe1/dilbert:latest -a
&lt;/pre&gt;

&lt;p&gt;Here's a sample command to download today's comic:&lt;/p&gt;
&lt;pre&gt;
docker run -d --name dilbert --rm -v $HOME/Pictures/dilbert:/home/user/Pictures/dilbert qwe1/dilbert:latest -t
&lt;/pre&gt;</content><category term="blog"></category><category term="dilbert"></category></entry><entry><title>Upgrading to Debian Buster</title><link href="debian-buster.html" rel="alternate"></link><published>2019-09-30T12:00:00+01:00</published><updated>2019-09-30T12:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-09-30:debian-buster.html</id><summary type="html">&lt;h1&gt;First impressions&lt;/h1&gt;
&lt;p&gt;I've been running &lt;a href="https://www.debian.org/"&gt;Debian&lt;/a&gt; systems at home for about 3+ years.&lt;/p&gt;
&lt;p&gt;I really like the distribution for the package availability and quality.&lt;/p&gt;
&lt;p&gt;Buster(Debian 10) comes with kernel 4.19, which is a long term release(LTS) kernel.&lt;/p&gt;
&lt;p&gt;On kernel.org, it's said to be supported until &lt;a href="https://www.kernel.org/category/releases.html"&gt;December …&lt;/a&gt;&lt;/p&gt;</summary><content type="html">&lt;h1&gt;First impressions&lt;/h1&gt;
&lt;p&gt;I've been running &lt;a href="https://www.debian.org/"&gt;Debian&lt;/a&gt; systems at home for about 3+ years.&lt;/p&gt;
&lt;p&gt;I really like the distribution for the package availability and quality.&lt;/p&gt;
&lt;p&gt;Buster(Debian 10) comes with kernel 4.19, which is a long term release(LTS) kernel.&lt;/p&gt;
&lt;p&gt;On kernel.org, it's said to be supported until &lt;a href="https://www.kernel.org/category/releases.html"&gt;December 2020&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;As is the case with kernel 3.16(used in Jessie) and 4.9(used in Stretch), I assume the support date will be adjusted to be in line with Buster's End of Life date.&lt;/p&gt;
&lt;p&gt;Xfce, the desktop environment I use, is still on 4.12 in this release. &lt;a href="https://xfce.org/download"&gt;4.14&lt;/a&gt; has been released recently but &lt;a href="https://metadata.ftp-master.debian.org/changelogs//main/x/xfce4/xfce4_4.14_changelog"&gt;it didn't make into buster&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;There's also a newer libreoffice release(6.1.5.2).&lt;/p&gt;
&lt;p&gt;Firefox-ESR, Thunderbird(60 ESR to 69 ESR) and Chromium will be upgraded with newer versions with time.&lt;/p&gt;
&lt;p&gt;There's also keepassxc in this release, which I've just started using since &lt;a href="https://www.keepassx.org/changelog"&gt;keepassx's last release was in 2016/02&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Issues and workarounds&lt;/h2&gt;
&lt;h3&gt;Xfce4 with i915 Intel igpu&lt;/h3&gt;
&lt;p&gt;I want to leave a link to &lt;a href="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=929834"&gt;https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=929834&lt;/a&gt; and a &lt;a href="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=929834#121"&gt;comment on that bug report&lt;/a&gt; as I've run into this issue on a laptop with Intel gpu.&lt;/p&gt;
&lt;p&gt;/etc/X11/xorg.conf.d/20-intel.conf:&lt;/p&gt;
&lt;pre&gt;
Section "Device"
  Identifier "Intel Graphics"
  Driver "intel"
EndSection
&lt;/pre&gt;

&lt;p&gt;I'll have to add this file/templating task to my playbooks from now on for this release.&lt;/p&gt;
&lt;p&gt;Update: Finally added this a couple days ago.&lt;/p&gt;
&lt;h3&gt;GPU passthrough issues with amdgpu and rx 480 card&lt;/h3&gt;
&lt;p&gt;For some reason, the same vfio setup I've used in Stretch stopped working after upgrading.&lt;/p&gt;
&lt;p&gt;At first, I thought the issue was withe Windows 10 virtual machine I've migrated from the previous install.&lt;/p&gt;
&lt;p&gt;It didn't even occur to me to check the lspci -nnk output.&lt;/p&gt;
&lt;p&gt;I'd start the VM, but libvirtd/virt-manager would hang and panic the kernel when trying to reboot.&lt;/p&gt;
&lt;p&gt;At anyrate, lspci -nnk output looked like this:&lt;/p&gt;
&lt;pre&gt;
02:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480] [1002:67df] (rev c7)
        Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Radeon RX 480 [1002:0b37]
        Kernel driver in use: amdgpu
        Kernel modules: amdgpu
02:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere HDMI Audio [Radeon RX 470/480 / 570/580/590] [1002:aaf0]
        Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere HDMI Audio [Radeon RX 470/480 / 570/580/590] [1002:aaf0]
        Kernel driver in use: vfio-pci
        Kernel modules: snd_hda_intel
&lt;/pre&gt;

&lt;p&gt;Amdgpu kernel module would grab the graphics controller, but not the sound card.&lt;/p&gt;
&lt;p&gt;What I needed was that vfio-pci would grab the entire card(02:00.0 and 02:00.1).&lt;/p&gt;
&lt;p&gt;After digging around with searches Google and &lt;a href="https://old.reddit.com/r/VFIO/comments/73og2w/cant_get_amdgpu_driver_to_stop_grabbing_2nd_gpu/"&gt;Reddit&lt;/a&gt;, I've found a possible workaround.&lt;/p&gt;
&lt;p&gt;As a reference, I've based my configs for Stretch on the pages from &lt;a href="https://scottlinux.com/2016/08/28/gpu-passthrough-with-kvm-and-debian-linux/"&gt;https://scottlinux.com/&lt;/a&gt; and the &lt;a href="https://wiki.archlinux.org/index.php/PCI_passthrough_via_OVMF"&gt;Arch linux wiki&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;For Buster, I've needed to add to my conf file in /etc/modprobe.d/vfio.conf:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;softdep amdgpu pre: vfio-pci&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;so now it looks like this:&lt;/p&gt;
&lt;pre&gt;
#Make vfio-pci a pre-dependency of the usual video modules
softdep amdgpu pre: vfio-pci
# rx 480
options vfio-pci ids=1002:67df,1002:aaf0
&lt;/pre&gt;

&lt;h3&gt;High IO delay with LUKS encrypted drives&lt;/h3&gt;
&lt;p&gt;I've noticed serious UI freezes when downloading larger files over a gigabit lan.&lt;/p&gt;
&lt;p&gt;My mouse pointer would stop responding to movements for several seconds.&lt;/p&gt;
&lt;p&gt;Here are two screenshots I made while downloading a larger file with firefox on my lan:&lt;/p&gt;
&lt;p&gt;&lt;img alt="First" src="photos/2019-09-28-22-27-59_1240x822a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Second" src="photos/2019-09-28-22-35-31_1240x822a.jpg"&gt;&lt;/p&gt;
&lt;p&gt;I have no workaround for this issue, I just reinstalled my desktop without LUKS.&lt;/p&gt;</content><category term="blog"></category><category term="debian"></category></entry><entry><title>Pihole Custom Domain Config</title><link href="pihole-custom-domain-config.html" rel="alternate"></link><published>2019-09-08T16:00:00+01:00</published><updated>2019-09-08T16:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-09-08:pihole-custom-domain-config.html</id><summary type="html">&lt;h1&gt;Running Pihole at home&lt;/h1&gt;
&lt;p&gt;I run pihole via &lt;a href="https://hub.docker.com/r/pihole/pihole/"&gt;docker&lt;/a&gt; on an old laptop.&lt;/p&gt;
&lt;h2&gt;Pihole Docker container as DHCP and DNS server&lt;/h2&gt;
&lt;p&gt;I got it configured via &lt;a href="https://docs.pi-hole.net/docker/DHCP/"&gt;the pihole docs&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To see my ansible playbook that works with Pihole and is run via compose, look at
&lt;a href="https://gitlab.com/richardskumat/ansible-playbooks-homelab/blob/e86cdda724359688f5e7528bddbdec5361f0c7b0/acer/acerlaptop.yml"&gt;this playbook&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I had to …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Running Pihole at home&lt;/h1&gt;
&lt;p&gt;I run pihole via &lt;a href="https://hub.docker.com/r/pihole/pihole/"&gt;docker&lt;/a&gt; on an old laptop.&lt;/p&gt;
&lt;h2&gt;Pihole Docker container as DHCP and DNS server&lt;/h2&gt;
&lt;p&gt;I got it configured via &lt;a href="https://docs.pi-hole.net/docker/DHCP/"&gt;the pihole docs&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To see my ansible playbook that works with Pihole and is run via compose, look at
&lt;a href="https://gitlab.com/richardskumat/ansible-playbooks-homelab/blob/e86cdda724359688f5e7528bddbdec5361f0c7b0/acer/acerlaptop.yml"&gt;this playbook&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I had to set the container into host networking mode, so it can
directly answer DNS and DHCP requests.&lt;/p&gt;
&lt;p&gt;Due to host networking mode, I had to comment out all port mappings from the compose
config.&lt;/p&gt;
&lt;p&gt;Via docker envs, it's also configured so that dnsmasq answers on all
network interfaces.&lt;/p&gt;
&lt;p&gt;Also the container required to have the NET_ADMIN capabilities added to it.&lt;/p&gt;
&lt;p&gt;What I haven't figured out yet is how I can put traefik in front of the pihole
web UI to avoid port conflicts with pihole's own webserver that's reachable via
port 80 on the host.&lt;/p&gt;
&lt;h2&gt;Pihole Logs and Stats&lt;/h2&gt;
&lt;p&gt;It shows some really useful info on your network.&lt;/p&gt;
&lt;p&gt;Examples of such info are, when full logging are enabled:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;what domains are queried and blocked&lt;/li&gt;
&lt;li&gt;what devices are making the requests&lt;/li&gt;
&lt;li&gt;what kind of requests devices are making(A, AAAA, PTR and so on)&lt;/li&gt;
&lt;li&gt;what DNS servers/forward destinations are used for the queries in what proportion(google, cloudflare, etc),
these stats include the blocklist and local cache&lt;/li&gt;
&lt;li&gt;there are lists for top permitted and blocked domains&lt;/li&gt;
&lt;li&gt;and also lists for top clients and a subset of top blocked clients&lt;/li&gt;
&lt;li&gt;my top performers on the blocked client list are a Windows 10 VM and my android phone&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Pihole DHCP settings&lt;/h2&gt;
&lt;p&gt;I was most interested in these parts of the settings as my ISP's router is very limited.&lt;/p&gt;
&lt;p&gt;When the DHCP is server is enabled, you can define a range of IP addresses to use on the network.&lt;/p&gt;
&lt;p&gt;Since my laptop(pihole host) is not the router on the network, I set the ISP's device as the gateway.&lt;/p&gt;
&lt;p&gt;This page also shows the currently active DHCP leases and also any static DHCP lease configurations.&lt;/p&gt;
&lt;p&gt;On the right side, there's a section where you can define what domain to use on the LAN.&lt;/p&gt;
&lt;p&gt;Note: this domain does need to have any A/AAAA records.&lt;/p&gt;
&lt;h2&gt;Dynamic DNS&lt;/h2&gt;
&lt;p&gt;This domain setting will put a search sub.domain.tld line into each Linux device's /etc/resolv.conf:&lt;/p&gt;
&lt;pre&gt;
# Generated by NetworkManager
search home.domain.tld
nameserver 192.168.0.69
&lt;/pre&gt;

&lt;p&gt;As a result, each device will be resolvable on the lan thanks to &lt;a href="https://en.wikipedia.org/wiki/Dynamic_DNS"&gt;Dynamic DNS&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;So I can connect to each device by either their hostname(eg acerlaptop) or full hostname which would be acerlaptop.home.domain.tld.&lt;/p&gt;
&lt;p&gt;This is most useful, when used with traefik and other containers. If configured properly, traefik can
then issue wildcards for each device where it runs.&lt;/p&gt;
&lt;p&gt;Resulting in the following wildcard certs, valid for:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;*.device.home.domain.tld&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;So a web host might be resolvable this way on the lan:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;servicename.device.home.domain.tld&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Thanks to Traefik, it will have a valid SSL certificate.&lt;/p&gt;
&lt;p&gt;However, this results in long hostnames in the browsers, which will annoy some people.&lt;/p&gt;
&lt;h2&gt;Adding Custom Domain names to Pihole&lt;/h2&gt;
&lt;p&gt;Since pihole uses Dnsmasq, we can also apply Dnsmasq configs of our own.&lt;/p&gt;
&lt;p&gt;In my case, I've placed my custom config file that has device specific subdomains
defined inside via an Ansible template task.&lt;/p&gt;
&lt;p&gt;An example of such task is:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;Template pihole conf file for local wildcard domains&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="nt"&gt;template&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;src&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;wildcard-local.conf.j2&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;dest&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/docker/pihole/etc-dnsmasq.d/wildcard-local.conf&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;owner&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;root&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;group&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;root&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="nt"&gt;mode&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;0644&lt;/span&gt;
&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="nt"&gt;tags&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;        &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;docker&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;This configuration file can be placed into the container's /etc/dnsmasq.d directory.&lt;/p&gt;
&lt;p&gt;If a static volume mapping is used for a container's config, eg:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span class="nt"&gt;volumes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/docker/pihole/etc-pihole:/etc/pihole&lt;/span&gt;
&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="p p-Indicator"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l l-Scalar l-Scalar-Plain"&gt;/var/docker/pihole/etc-dnsmasq.d:/etc/dnsmasq.d&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;then our config file needs to be placed inside /var/docker/pihole/etc-dnsmasq.d on the host that
runs pihole. Then inside the container, it will look like that a new config file has appeared.&lt;/p&gt;
&lt;p&gt;If I want to restart the dnsmasq process inside the container, without restarting the entire container,
I can just simply exec:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;docker&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nb"&gt;exec&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;ctname&lt;span class="w"&gt; &lt;/span&gt;pihole&lt;span class="w"&gt; &lt;/span&gt;restartdns
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;inside the container. This will apply our new configuration file straight away.&lt;/p&gt;</content><category term="blog"></category><category term="pihole"></category><category term="ansible"></category><category term="docker"></category></entry><entry><title>Running Docker-compose from Ansible playbooks</title><link href="docker-compose-from-ansible-playbook.html" rel="alternate"></link><published>2019-09-01T20:00:00+01:00</published><updated>2019-09-01T20:00:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-09-01:docker-compose-from-ansible-playbook.html</id><summary type="html">&lt;h1&gt;Running Docker-compose from Ansible playbooks&lt;/h1&gt;
&lt;p&gt;On my home devices, I run and maintain my docker containers(ct-s
with my Ansible playbooks.&lt;/p&gt;
&lt;h2&gt;But why use Docker-compose and not Docker Swarm or Kubernetes&lt;/h2&gt;
&lt;p&gt;Because I only have four devices that I run docker ct-s on,
and each serve a dedicated function at …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Running Docker-compose from Ansible playbooks&lt;/h1&gt;
&lt;p&gt;On my home devices, I run and maintain my docker containers(ct-s
with my Ansible playbooks.&lt;/p&gt;
&lt;h2&gt;But why use Docker-compose and not Docker Swarm or Kubernetes&lt;/h2&gt;
&lt;p&gt;Because I only have four devices that I run docker ct-s on,
and each serve a dedicated function at my place.&lt;/p&gt;
&lt;p&gt;Here are the following devices:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Old Acer laptop&lt;/li&gt;
&lt;li&gt;HP Gen8 microserver&lt;/li&gt;
&lt;li&gt;Custom built desktop&lt;/li&gt;
&lt;li&gt;HP laptop&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Since I've got each devices dedicated to a certain function,
I just prefer the simplicity of knowing what docker ct-s each device is running
as declared in a playbook with a docker_compose task.&lt;/p&gt;
&lt;h2&gt;How&lt;/h2&gt;
&lt;p&gt;My current playbooks are in &lt;a href="https://gitlab.com/richardskumat/ansible-playbooks-homelab"&gt;https://gitlab.com/richardskumat/ansible-playbooks-homelab&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Each device is assigned into a group.&lt;/p&gt;
&lt;p&gt;Each group has a group_vars directory for variables and secrets.
These directories are not public.&lt;/p&gt;
&lt;p&gt;In each groups directory, where their playbooks reside,
I have symlinked the homelab/group_vars directory
so I can use them with vagrant testing.
When I do a vagrant up in a group's directory,
there's a task in the Vagrantfile that runs the group's playbooks.&lt;/p&gt;
&lt;p&gt;I didn't have the group_vars directory symlinked into each subdirectory,
then the vagrant's playbook test runs fail with XYZ variable undefined and so on.&lt;/p&gt;
&lt;p&gt;Here's a tree output of how my playbooks look are structured:&lt;/p&gt;
&lt;pre&gt;
user@host:~/wherever/homelab$ tree
.
├── acer
│   ├── acerlaptop.yml
│   ├── group_vars -&gt; ../group_vars
│   ├── interfaces.j2
│   ├── readme.md
│   ├── Vagrantfile
│   └── wildcard-local.conf.j2.example
├── add_remotes_back.sh
├── client
│   ├── client.yml
│   ├── group_vars -&gt; ../group_vars
│   ├── readme.md
│   ├── sysctl-local.conf.j2
│   └── Vagrantfile
├── group_vars
│   ├── acer
│   ├── all
│   ├── desktop
│   ├── hpg8
│   ├── laptop
│   └── rpi
├── hosts
├── hpg8
│   ├── group_vars -&gt; ../group_vars
│   ├── hpg8-dc.yml
│   ├── hpg8.yml
│   ├── readme.md
│   └── Vagrantfile
├── LICENSE
├── README.md
├── reboot.yml
├── rpi
│   ├── group_vars -&gt; ../group_vars
│   ├── raspi-debug.yml
│   ├── readme.md
│   ├── rpi3-dc.yml
│   └── rpi.yml
└── shutdown.yml
&lt;/pre&gt;

&lt;p&gt;I'm currently going to change my playbooks to use import_task
for the docker_compose playbook.&lt;/p&gt;
&lt;p&gt;Then each playbook is structured according to the following thinking:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;establish connections details(host groups, remote user and become method)&lt;/li&gt;
&lt;li&gt;roles: each device runs a couple of Ansible roles&lt;/li&gt;
&lt;li&gt;tasks: extra tasks needed done&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The docker_compose task is also part of these tasks, however the indentation
requirements for yaml are unpleasant.&lt;/p&gt;
&lt;p&gt;Fortunately, &lt;a href="https://code.visualstudio.com/"&gt;VSCode&lt;/a&gt; is really good in
showing indentation and syntax errors.&lt;/p&gt;
&lt;p&gt;I want to move them into separate yml files, so they're more readable.&lt;/p&gt;
&lt;h2&gt;Traefik for proxying and Let's Encrypt(LE) certificates(cert)&lt;/h2&gt;
&lt;p&gt;I also run traefik on each device and it serves as a reverse proxy
for the other containers having a web interface.&lt;/p&gt;
&lt;p&gt;It's also configured to create LE certs with
&lt;a href="https://letsencrypt.org/docs/challenge-types/"&gt;DNS-01 challenge&lt;/a&gt;,
using &lt;a href="https://www.cloudflare.com/en-gb/"&gt;Cloudflare&lt;/a&gt; as a DNS provider.&lt;/p&gt;
&lt;h2&gt;Looking into better alternatives&lt;/h2&gt;
&lt;p&gt;I'm really satisfied with the simplicity of ansible and
the docker_compose module.&lt;/p&gt;
&lt;p&gt;The ct-s I run are documented in each group's docker_compose files/tasks
so I know what personal device runs what containers.&lt;/p&gt;
&lt;p&gt;There are better alternatives, such as &lt;a href="https://docs.docker.com/engine/swarm/"&gt;Docker Swarm&lt;/a&gt;
and &lt;a href="https://kubernetes.io/"&gt;Kubernetes&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I intend to look Kubernetes and Swarm in the future,
maybe test them out in their own virtual machines.&lt;/p&gt;
&lt;p&gt;Swarm is also part of Docker CE, so if I wanted to, I could use it straight away.&lt;/p&gt;</content><category term="blog"></category><category term="docker"></category><category term="ansible"></category></entry><entry><title>Playing around with Gitlab.com's CI and Docker Registry</title><link href="gitlabcomci-playground.html" rel="alternate"></link><published>2019-08-15T12:15:00+01:00</published><updated>2019-08-15T12:15:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-08-15:gitlabcomci-playground.html</id><summary type="html">&lt;h1&gt;Dabbling with Gitlab&lt;/h1&gt;
&lt;p&gt;I've got a Gitlab Community Edition(CE) instance running at home with
3 runners on separate devices.&lt;/p&gt;
&lt;p&gt;I'd like to say I've become familiar with the basics of Gitlab's ci,
however I haven't done much with the continuous delivery part.&lt;/p&gt;
&lt;p&gt;What I'd like to do with the …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Dabbling with Gitlab&lt;/h1&gt;
&lt;p&gt;I've got a Gitlab Community Edition(CE) instance running at home with
3 runners on separate devices.&lt;/p&gt;
&lt;p&gt;I'd like to say I've become familiar with the basics of Gitlab's ci,
however I haven't done much with the continuous delivery part.&lt;/p&gt;
&lt;p&gt;What I'd like to do with the CI part is how I could test a repo simultaneously
on different versions of software/OS-s at the same time,
without too much copy-pasting of same block of code.&lt;/p&gt;
&lt;p&gt;Eg:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;testing the same ansible role with different releases of Debian&lt;/li&gt;
&lt;li&gt;building docker images with different versions of Debian releases for comparison purposes&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The only CD so far I have been doing at home is pushing my own docker images to dockerhub, which is not
complicated at all.&lt;/p&gt;
&lt;h2&gt;Pushing Docker images from home&lt;/h2&gt;
&lt;p&gt;I've got a few images on &lt;a href="https://hub.docker.com/u/qwe1"&gt;Dockerhub&lt;/a&gt;, which I've been building,
testing and pushing from home.&lt;/p&gt;
&lt;p&gt;I've got daily scheduled jobs running in my private Gitlab instance that rebuild and push
the docker images early in the morning.&lt;/p&gt;
&lt;p&gt;However, this requires me to keep my own machines powered on all the time, even if I wanted to go away
someplace.&lt;/p&gt;
&lt;p&gt;I could just power them off while gone, but then the images wouldn't be rebuilt daily.&lt;/p&gt;
&lt;p&gt;So now I came to the conclusion, it'd be smarter to utilize Gitlab.com's
free runner instances to build and push images.&lt;/p&gt;
&lt;p&gt;At this time, I only publish on Dockerhub, but this way I could push both to Gitlab.com's
docker registry and dockerhub to provide a bit of redundancy for myself.&lt;/p&gt;
&lt;p&gt;My only concern with building docker images on Gitlab.com would be needing to store my Dockerhub
login details in each repo's CI/CD vars settings, which would be really cumbersome to do manually.&lt;/p&gt;
&lt;h2&gt;Terraform and Gitlab.com&lt;/h2&gt;
&lt;p&gt;Looking at Terraform's documentation in the &lt;a href="https://www.terraform.io/docs/providers/type/vcs-index.html"&gt;providers section&lt;/a&gt;,
there is a &lt;a href="https://www.terraform.io/docs/providers/gitlab/index.html"&gt;VCS/Gitlab&lt;/a&gt; provider.&lt;/p&gt;
&lt;p&gt;Further reading up on these pages could save me some time in the future.&lt;/p&gt;
&lt;h2&gt;Gitlab repo playground&lt;/h2&gt;
&lt;p&gt;I made a dummy git repo on both on public &lt;a href="https://gitlab.com/richardskumat/playground/tree/188d3038ffd1194f0986d93645f34af87eab3c20"&gt;Gitlab.com&lt;/a&gt;
and my private Gitlab instance.&lt;/p&gt;
&lt;p&gt;The purpose of this repo is to test/play with Gitlab's CI.&lt;/p&gt;
&lt;p&gt;What I've managed to do at this time was to build and push a docker image to Gitlab's internal CI
without specifying any CI/CD vars in settings manually.&lt;/p&gt;
&lt;p&gt;Here's the raw version of the &lt;a href="https://gitlab.com/richardskumat/playground/raw/188d3038ffd1194f0986d93645f34af87eab3c20/.gitlab-ci.yml"&gt;Gitlab CI file&lt;/a&gt;
that made this possible.&lt;/p&gt;
&lt;p&gt;Here's a link to Gitlab.com's doc page of &lt;a href="https://docs.gitlab.com/ee/ci/variables/predefined_variables.html"&gt;predefined environment variables&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Some comments below for the vars/commands in that CI file above:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;"$CI_REGISTRY_USER": this seems to return gitlab-ci-token in the build logs, yet this is the &lt;a href="https://gitlab.com/richardskumat/playground/-/jobs/270010078"&gt;only var that let me log into Gitlab's
docker registry&lt;/a&gt;, yet when pushing the docker image to Gitlab's registry, &lt;a href="https://gitlab.com/richardskumat/playground/-/jobs/270007049"&gt;I'd get requested access to the resource is denied errors&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;"$CI_REGISTRY": this returns the registry on the Gitlab instance if it's activated&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" "$CI_REGISTRY" --password-stdin: This is more secure than passing -p password to docker login for
some reason&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;docker push $CI_REGISTRY/$GITLAB_USER_LOGIN/$CI_PROJECT_NAME:$CI_COMMIT_SHA: This seems to work only if the person initiating the build is also the owner of the project, because of $GITLAB_USER_LOGIN being: The login username of the user who started the job. Eg on my private instance, my projects are under a non-admin user. If I run a pipeline as a different user, the build fails.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;$CI_PROJECT_NAMESPACE: The project namespace (username or groupname) that is currently being built. This seems to be a better choice than $GITLAB_USER_LOGIN to change in the docker push URL as it also works when a pipeline is launched by a different user.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;</content><category term="blog"></category><category term="gitlab"></category></entry><entry><title>Second blog post</title><link href="second-blog-post.html" rel="alternate"></link><published>2019-08-08T23:15:00+01:00</published><updated>2019-08-08T23:15:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-08-08:second-blog-post.html</id><summary type="html">&lt;h1&gt;Second blog post&lt;/h1&gt;
&lt;p&gt;For the time being this site will be hosted on netlify,
at &lt;a href="https://blog.richardskumat.com"&gt;https://blog.richardskumat.com&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;A fun project would be to setup the blog subdomain
to automatically fail over to either Github
or Gitlab pages if Netlify's servers were down
or if they terminated my account …&lt;/p&gt;</summary><content type="html">&lt;h1&gt;Second blog post&lt;/h1&gt;
&lt;p&gt;For the time being this site will be hosted on netlify,
at &lt;a href="https://blog.richardskumat.com"&gt;https://blog.richardskumat.com&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;A fun project would be to setup the blog subdomain
to automatically fail over to either Github
or Gitlab pages if Netlify's servers were down
or if they terminated my account for
some reason, but at this point in time it'd be
a waste of time, and I'm not even sure where I
should get started with this idea.&lt;/p&gt;
&lt;h2&gt;Configuration&lt;/h2&gt;
&lt;p&gt;So after setting up Gitlab and Github repos with
the blog repo, I've decided to configure my netlify account
to publish from the Gitlab repo.&lt;/p&gt;
&lt;p&gt;Also configured my DNS records with terraform to point
the blog subdomain with a CNAME record to netlify's
subdomain where the site is hosted.&lt;/p&gt;
&lt;p&gt;Then added a custom domain on netlify's dashboard,
and since the cname record already existed, it was easy
enough to enable SSL for the website.&lt;/p&gt;</content><category term="blog"></category><category term="blog"></category></entry><entry><title>First blog post</title><link href="first-blog-post.html" rel="alternate"></link><published>2019-08-08T21:15:00+01:00</published><updated>2019-08-08T21:15:00+01:00</updated><author><name>Richard Skumat</name></author><id>tag:None,2019-08-08:first-blog-post.html</id><summary type="html">&lt;h1&gt;First blog post&lt;/h1&gt;
&lt;p&gt;This is the first blog post to see how the new blog will look.&lt;/p&gt;
&lt;p&gt;The blog posts will be written in Markdown and published with Pelican.&lt;/p&gt;
&lt;p&gt;To-do:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Settle on a theme&lt;/li&gt;
&lt;li&gt;Settle on a site structure&lt;/li&gt;
&lt;li&gt;Setup CI/CD and decide which host to use(leaning towards …&lt;/li&gt;&lt;/ul&gt;</summary><content type="html">&lt;h1&gt;First blog post&lt;/h1&gt;
&lt;p&gt;This is the first blog post to see how the new blog will look.&lt;/p&gt;
&lt;p&gt;The blog posts will be written in Markdown and published with Pelican.&lt;/p&gt;
&lt;p&gt;To-do:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Settle on a theme&lt;/li&gt;
&lt;li&gt;Settle on a site structure&lt;/li&gt;
&lt;li&gt;Setup CI/CD and decide which host to use(leaning towards Gitlab or Netlify at this point)&lt;/li&gt;
&lt;li&gt;Setup DNS via terraform for the site&lt;/li&gt;
&lt;li&gt;Start publishing&lt;/li&gt;
&lt;li&gt;Check up on my netlify account&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Notes on pushing to Github pages&lt;/h2&gt;
&lt;p&gt;Based on &lt;a href="https://docs.travis-ci.com/user/deployment/pages/"&gt;https://docs.travis-ci.com/user/deployment/pages/&lt;/a&gt; and &lt;a href="https://pages.github.com/"&gt;https://pages.github.com/&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To publish to Github pages via Travis CI, ideally the following things are required:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;a working CI config file, the .travis.yml in this repo can be used as a base&lt;/li&gt;
&lt;li&gt;set $GITHUB_TOKEN found in this repo's on https://github.com/settings/tokens/new, select Scope repo/public_repo.
  Selecting this scope should be enough&lt;/li&gt;
&lt;li&gt;having gh-pages branch in the repo, so travis-bot can force push the created static files to this branch.
  this can achieved by:
  git branch gh-pages
  git push github gh-pages&lt;/li&gt;
&lt;li&gt;on https://github.com/user/project/settings, set Github Pages source to gh-pages branch
  which then sets the gh-pages branch as the source of Github Pages. This is the same branch where
  Travis pushes to. So Travis reads from master, then pushes the output of pelican to gh-pages,
  then Github publishes from gh-pages branch&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Notes on publishing to Gitlab pages&lt;/h2&gt;
&lt;p&gt;Requirements:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;a working CI config file, the .gitlab-ci.yml in this repo can be used as a base&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;See &lt;a href="https://gitlab.com/pages/pelican"&gt;https://gitlab.com/pages/pelican&lt;/a&gt; for a pelican example, which this site is based on.&lt;/p&gt;
&lt;h2&gt;Source code&lt;/h2&gt;
&lt;p&gt;My own links for publishing:&lt;/p&gt;
&lt;p&gt;Canonical URL of my blog, as of 2019-12-05:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://www.richardskumat.com/"&gt;https://www.richardskumat.com/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Used to be blog.domain instead of www, but changed that
later on.&lt;/p&gt;</content><category term="blog"></category><category term="blog"></category></entry></feed>