aboutsummaryrefslogtreecommitdiff
path: root/content/docs/adyxax.org
diff options
context:
space:
mode:
Diffstat (limited to 'content/docs/adyxax.org')
-rw-r--r--content/docs/adyxax.org/_index.md22
-rw-r--r--content/docs/adyxax.org/services/_index.md8
-rw-r--r--content/docs/adyxax.org/services/checkmk.md16
-rw-r--r--content/docs/adyxax.org/services/git.md42
-rw-r--r--content/docs/adyxax.org/services/nethack.md56
-rw-r--r--content/docs/adyxax.org/services/www.md47
6 files changed, 191 insertions, 0 deletions
diff --git a/content/docs/adyxax.org/_index.md b/content/docs/adyxax.org/_index.md
new file mode 100644
index 0000000..9d7b25d
--- /dev/null
+++ b/content/docs/adyxax.org/_index.md
@@ -0,0 +1,22 @@
+---
+title: "adyxax.org"
+description: a set of pages about the computer infrastructure powering this website and other services
+---
+
+## What is adyxax.org?
+
+adyxax.org is very much like a small personnal cloud of inexpensive servers hosted here and there. I am using my experience as a
+sysadmin to make it all work and provide various services that are useful to me and people that are close to me. As a good sysadmin, I am trying to be lazy and build the most self
+maintainable solution, with as little maintenance overhead as possible.
+
+It used to rely on mostly gentoo (and some optional openbsd) servers interconnected with point to point openvpn links. Services ran inside lxd on alpine linux containers. Communications between all those services work
+thanks to dynamic routing with bird and ospf along those openvpn links. I made extensive use of ansible to orchestrate all that, deploy the containers and manage them.
+
+Even though it worked really well for years, I do not plan to blog a lot about this setup... but that can change if someone interested writes me at julien -DOT- dessaux -AT- adyxax -DOT- org. On this new documentation site I plan to focus on how I am migrating some of it on kubernetes, because even if it has always worked well it still is a rather unusual infrastructure. Even if I am proud of it, it is stable and easy and comfortable... It is not good for me to not look deeper into new technologies. Gentoo, OpenBSD and LXD is not the most popular combination out there. I will not abandon it completely, but working on more employable skills will do me good.
+
+## Why write about it?
+
+As a system and network administrator I believe I have a deep understanding of linux and other unix like operating systems, networking and storage, and even with all that knowledge and experience getting on kubernetes is hard. Deploying kubernetes itself is not hard, but there are so so many choices that you make each steps of the way that will define how hard it is going to be to maintain and debug. Choosing what kubernetes flavor to deploy is one tough choice, choosing how to deploy it is another. Then choosing your network provider is a juicy one, so many subtle differences come into play!
+
+I believe there are way too many blogs that focus on the hello world aspects and quick and dirty deployments... and those come out way too often in google search results. Writing about the choices I made will also help me reflect on them as this infrastructure evolves and grows.
+
diff --git a/content/docs/adyxax.org/services/_index.md b/content/docs/adyxax.org/services/_index.md
new file mode 100644
index 0000000..405c2ca
--- /dev/null
+++ b/content/docs/adyxax.org/services/_index.md
@@ -0,0 +1,8 @@
+---
+title: "Services"
+linkTitle: "Services"
+weight: 1
+description: >
+ Here are the services provided by adyxax.org
+---
+
diff --git a/content/docs/adyxax.org/services/checkmk.md b/content/docs/adyxax.org/services/checkmk.md
new file mode 100644
index 0000000..f8a8bf6
--- /dev/null
+++ b/content/docs/adyxax.org/services/checkmk.md
@@ -0,0 +1,16 @@
+---
+title: "checkmk"
+linkTitle: "checkmk"
+weight: 1
+description: >
+ checkmk
+---
+
+TODO
+
+## Updating
+
+- Download latest raw edition package from http://mathias-kettner.com/check_mk_download_version.php?HTML=yes&version=1.2.8p15&edition=cre and install it.
+- `run omd backup adyxax adyxax.bak`
+- `run omd update adyxax`
+- If all went well, apt purge the previous check_mk version to free space.
diff --git a/content/docs/adyxax.org/services/git.md b/content/docs/adyxax.org/services/git.md
new file mode 100644
index 0000000..a7a9374
--- /dev/null
+++ b/content/docs/adyxax.org/services/git.md
@@ -0,0 +1,42 @@
+---
+title: "git"
+weight: 1
+description: >
+ adyxax.org git server
+---
+
+git.adyxax.org is a gitea instance. For about 10 years I used a gitolite installation but I finally went for a gui instead in order to host repositories for non tech people.
+
+## Preparing the postgresql database
+
+I am currently hosting this gitea instance on an OpenBSD server. Obviously postgresql is packaged on this system so the installation is as simple as :
+{{< highlight sh >}}
+pkg_add postgresql-server
+su - __postgresql
+mkdir /var/postgresql/data
+initdb -D /var/postgresql/data -U postgres -A scram-sha-256 -E UTF8 -W
+rcctl enable postgresql
+rcctl start postgresql
+su - ___postgresql
+psql -U postgresql
+CREATE ROLE gitea WITH LOGIN PASSWORD 'XXXXX';
+CREATE DATABASE gitea WITH OWNER gitea TEMPLATE template0 ENCODING UTF8 LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8';
+{{< /highlight >}}
+
+Since it is OpenBSD the defaults are secure for a local usage, therefore no other configuration is necessary.
+
+## Installing gitea
+
+Gitea is packaged on OpenBSD so the installation is as simple as :
+{{< highlight sh >}}
+pkg_add gitea
+nvim /etc/gitea/app.ini
+rcctl enable gitea
+rcctl start gitea
+{{< /highlight >}}
+
+## TODO Serving the website
+
+{{< highlight sh >}}
+nvim /etc/h2o/h2o.conf
+{{< /highlight >}}
diff --git a/content/docs/adyxax.org/services/nethack.md b/content/docs/adyxax.org/services/nethack.md
new file mode 100644
index 0000000..e9aa7a7
--- /dev/null
+++ b/content/docs/adyxax.org/services/nethack.md
@@ -0,0 +1,56 @@
+---
+title: "nethack"
+linkTitle: "nethack"
+weight: 1
+description: >
+ nethack
+---
+
+## dgamelaunch
+
+TODO
+
+{{< highlight sh >}}
+groupadd -r games
+useradd -r -g games nethack
+git clone
+{{< /highlight >}}
+
+## nethack
+
+TODO
+
+{{< highlight sh >}}
+{{< /highlight >}}
+
+## scores script
+
+TODO
+
+{{< highlight sh >}}
+{{< /highlight >}}
+
+## copying shared libraries
+
+{{< highlight sh >}}
+cd /opt/nethack
+for i in `ls bin`; do for l in `ldd bin/$i | tail -n +1 | cut -d'>' -f2 | awk '{print $1}'`; do if [ -f $l ]; then echo $l; cp $l lib64/; fi; done; done
+for l in `ldd dgamelaunch | tail -n +1 | cut -d'>' -f2 | awk '{print $1}'`; do if [ -f $l ]; then echo $l; cp $l lib64/; fi; done
+for l in `ldd nethack-3.7.0-r1/games/nethack | tail -n +1 | cut -d'>' -f2 | awk '{print $1}'`; do if [ -f $l ]; then echo $l; cp $l lib64/; fi; done
+{{< /highlight >}}
+
+## making device nodes
+
+TODO! For now I mount all of /dev in the chroot :
+{{< highlight sh >}}
+#mknod -m 666 dev/ptmx c 5 2
+mount -R /dev /opt/nethack/dev
+{{< /highlight >}}
+
+## debugging
+
+{{< highlight sh >}}
+gdb chroot
+run --userspec=nethack:games /opt/nethack/ /dgamelaunch
+{{< /highlight >}}
+
diff --git a/content/docs/adyxax.org/services/www.md b/content/docs/adyxax.org/services/www.md
new file mode 100644
index 0000000..852cfcc
--- /dev/null
+++ b/content/docs/adyxax.org/services/www.md
@@ -0,0 +1,47 @@
+---
+title: "www"
+linkTitle: "www"
+weight: 1
+description: >
+ adyxax.org main entry website. www.adyxax.org, wiki.adyxax.org and blog.adyxax.org all point here.
+---
+
+This is the website you are currently reading. It is a static website built using [hugo](https://github.com/gohugoio/hugo). This article details how I
+installed hugo, how I initialised this website and how I manage it. I often refer to it as wiki.adyxax.org because I hosted a unique dokuwiki for a long
+time as my main website (and a pmwiki before that), but with hugo it has become more than that. It is now a mix of wiki, blog and showcase of my work and interests.
+
+For a log of how I made the initial setup, see [this blog article.]({{< relref "/blog/miscellaneous/switching-to-hugo.md" >}})
+
+## Installing hugo
+
+I am currently hosting this website on an OpenBSD server. Hugo is packaged on this system so the installation is as simple as :
+{{< highlight sh >}}
+pkg_add hugo--extended
+{{< / highlight >}}
+
+## Bootstraping this site
+
+The website is on my gitea :
+{{< highlight sh >}}
+cd /var/www/htdocs
+git clone --recurse-submodules _gitea@git.adyxax.org:adyxax/www.git
+cd www
+{{< / highlight >}}
+
+The docsy theme requires two nodejs programs to run :
+{{< highlight sh >}}
+npm install -D --save autoprefixer
+npm install -D --save postcss-cli
+{{< / highlight >}}
+
+## hugo commands
+
+To publish the website in the `public` folder :
+{{< highlight sh >}}
+hugo --minify
+{{< / highlight >}}
+
+## TODO
+
+TODO deploy on push to git.adyxax.org
+TODO web server config