Bump
This commit is contained in:
parent
ca0ebe93cc
commit
0a8f9332b2
7 changed files with 63 additions and 7 deletions
5
content/en/blog/kubernetes/_index.md
Normal file
5
content/en/blog/kubernetes/_index.md
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
title: "Kubernetes"
|
||||||
|
linkTitle: "Kubernetes"
|
||||||
|
weight: 40
|
||||||
|
---
|
24
content/en/blog/kubernetes/pg_dump_restore.md
Normal file
24
content/en/blog/kubernetes/pg_dump_restore.md
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
---
|
||||||
|
title: "Dump and restore a postgresql database on kubernetes"
|
||||||
|
linkTitle: "Dump and restore a postgresql database"
|
||||||
|
date: 2020-06-25
|
||||||
|
---
|
||||||
|
|
||||||
|
## Dumping
|
||||||
|
Assuming we are working with a postgresql statefulset, our namespace is named `miniflux` and our master pod is named `db-postgresql-0`, trying to
|
||||||
|
dump a database named `miniflux`:
|
||||||
|
{{< highlight sh >}}
|
||||||
|
export POSTGRES_PASSWORD=$(kubectl get secret --namespace miniflux db-postgresql -o jsonpath="{.data.postgresql-password}" | base64 --decode)
|
||||||
|
kubectl run db-postgresql-client --rm --tty -i --restart='Never' --namespace miniflux --image docker.io/bitnami/postgresql:11.8.0-debian-10-r19 --env="PGPASSWORD=$POSTGRES_PASSWORD" --command -- pg_dump --host db-postgresql -U postgres -d miniflux > miniflux.sql-2020062501
|
||||||
|
{{< /highlight >}}
|
||||||
|
|
||||||
|
## Restoring
|
||||||
|
|
||||||
|
Assuming we are working with a postgresql statefulset, our namespace is named `miniflux` and our master pod is named `db-postgresql-0`, trying to
|
||||||
|
restore a database named `miniflux`:
|
||||||
|
{{< highlight sh >}}
|
||||||
|
kubectl -n miniflux cp miniflux.sql-2020062501 db-postgresql-0:/tmp/miniflux.sql
|
||||||
|
kubectl -n miniflux exec -ti db-postgresql-0 -- psql -U postgres -d miniflux
|
||||||
|
miniflux=# \i /tmp/miniflux.sql
|
||||||
|
kubectl -n miniflux exec -ti db-postgresql-0 -- rm /tmp/miniflux.sql
|
||||||
|
{{< /highlight >}}
|
19
content/en/blog/miscellaneous/osm-overlay-example.md
Normal file
19
content/en/blog/miscellaneous/osm-overlay-example.md
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
---
|
||||||
|
title: "OpenStreetMap overlay example"
|
||||||
|
linkTitle: "OpenStreetMap overlay example"
|
||||||
|
date: 2020-05-19
|
||||||
|
description: >
|
||||||
|
An example of how to query things visually on OpenStreetMap
|
||||||
|
---
|
||||||
|
|
||||||
|
http://overpass-turbo.eu/
|
||||||
|
{{< highlight html >}}
|
||||||
|
<osm-script>
|
||||||
|
<query type="node">
|
||||||
|
<has-kv k="amenity" v="recycling"/>
|
||||||
|
<bbox-query {{bbox}}/>
|
||||||
|
</query>
|
||||||
|
<!-- print results -->
|
||||||
|
<print mode="body"/>
|
||||||
|
</osm-script>
|
||||||
|
{{< /highlight >}}
|
|
@ -5,3 +5,7 @@ date: 2019-12-19
|
||||||
description: >
|
description: >
|
||||||
I switched my personal wiki from dokuwiki to Hugo
|
I switched my personal wiki from dokuwiki to Hugo
|
||||||
---
|
---
|
||||||
|
|
||||||
|
This is the website you are currently reading. It is a static website built using 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.
|
||||||
|
|
||||||
|
[Here is the link to the full article describing how I achieved that.]({{< relref "/docs/adyxax.org/services/www.md" >}})
|
||||||
|
|
|
@ -33,4 +33,4 @@ I joined Alterway in October 2016 for a more technical role and a bit of a caree
|
||||||
|
|
||||||
## How to get in touch
|
## How to get in touch
|
||||||
|
|
||||||
You can write me an email at julien[dot]dessaux[at]adyxax[dot]org, I will answer.
|
You can write me an email at julien -DOT- dessaux -AT- adyxax -DOT- org, I will answer.
|
||||||
|
|
|
@ -8,14 +8,18 @@ description: >
|
||||||
|
|
||||||
## What is adyxax.org?
|
## What is adyxax.org?
|
||||||
|
|
||||||
adyxax.org is very much like a small personnal cloud of servers hosted here and there. I am using my experience as a
|
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
|
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.
|
maintainable solution, with as little maintenance overhead as possible.
|
||||||
|
|
||||||
It relies on mostly gentoo (and some optional openbsd) servers interconnected with point to point openvpn links. Services run inside lxd containers and communications between all those services work
|
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.
|
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?
|
## Why write about it?
|
||||||
|
|
||||||
It is a rather unusual infrastructure that I am proud of, and writing about it helps me to reflect on what I built. Gentoo, OpenBSD and LXD is not the most popular combination of
|
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!
|
||||||
technologies but I leveraged it to build something simple, flexible and I believe somewhat elegant and beautiful.
|
|
||||||
|
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.
|
||||||
|
|
||||||
|
|
|
@ -40,6 +40,6 @@ cp /boot/System.map-${VERSION} System.map
|
||||||
(cd usr ; make gen_init_cpio)
|
(cd usr ; make gen_init_cpio)
|
||||||
make modules_prepare
|
make modules_prepare
|
||||||
emerge @module-rebuild
|
emerge @module-rebuild
|
||||||
genkernel --install initramfs
|
genkernel --install initramfs --ssh-host-keys=create-from-host
|
||||||
grub-mkconfig -o /boot/grub/grub.cfg
|
grub-mkconfig -o /boot/grub/grub.cfg
|
||||||
{{< / highlight >}}
|
{{< / highlight >}}
|
||||||
|
|
Loading…
Add table
Reference in a new issue