aboutsummaryrefslogtreecommitdiff
path: root/content/en/blog
diff options
context:
space:
mode:
authorJulien Dessaux2020-06-26 00:06:30 +0200
committerJulien Dessaux2020-06-26 00:06:30 +0200
commit0a8f9332b2ea3bfb903a951b5f753c0bc7ec4044 (patch)
tree8a29fb1882da46a6fae7f0f3b8a19cf29e4ea30b /content/en/blog
parentFixed permissions (diff)
downloadwww-0a8f9332b2ea3bfb903a951b5f753c0bc7ec4044.tar.gz
www-0a8f9332b2ea3bfb903a951b5f753c0bc7ec4044.tar.bz2
www-0a8f9332b2ea3bfb903a951b5f753c0bc7ec4044.zip
Bump
Diffstat (limited to 'content/en/blog')
-rw-r--r--content/en/blog/kubernetes/_index.md5
-rw-r--r--content/en/blog/kubernetes/pg_dump_restore.md24
-rw-r--r--content/en/blog/miscellaneous/osm-overlay-example.md19
-rw-r--r--content/en/blog/miscellaneous/switching-to-hugo.md4
4 files changed, 52 insertions, 0 deletions
diff --git a/content/en/blog/kubernetes/_index.md b/content/en/blog/kubernetes/_index.md
new file mode 100644
index 0000000..3545b68
--- /dev/null
+++ b/content/en/blog/kubernetes/_index.md
@@ -0,0 +1,5 @@
+---
+title: "Kubernetes"
+linkTitle: "Kubernetes"
+weight: 40
+---
diff --git a/content/en/blog/kubernetes/pg_dump_restore.md b/content/en/blog/kubernetes/pg_dump_restore.md
new file mode 100644
index 0000000..9aafb63
--- /dev/null
+++ b/content/en/blog/kubernetes/pg_dump_restore.md
@@ -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 >}}
diff --git a/content/en/blog/miscellaneous/osm-overlay-example.md b/content/en/blog/miscellaneous/osm-overlay-example.md
new file mode 100644
index 0000000..2787a6e
--- /dev/null
+++ b/content/en/blog/miscellaneous/osm-overlay-example.md
@@ -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 >}}
diff --git a/content/en/blog/miscellaneous/switching-to-hugo.md b/content/en/blog/miscellaneous/switching-to-hugo.md
index 1bb0c43..7468667 100644
--- a/content/en/blog/miscellaneous/switching-to-hugo.md
+++ b/content/en/blog/miscellaneous/switching-to-hugo.md
@@ -5,3 +5,7 @@ date: 2019-12-19
description: >
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" >}})