I Built an Async Notification Flow That Called Back Into Itself

The problem I was solving I was working on a notification flow where customers had to confirm that they had seen a message and followed its instructions. The confirmation came through a public API on our website. Accepting the confirmation was quick, but the follow-up work was not. The backend needed to create snapshots, perform expensive computation, call another service, and write more records to DynamoDB. I did not want the customer waiting for all of that work behind a spinner. ...

August 5, 2025

Building and serving a production Hugo site with Docker and Nginx

Update, November 2026: I no longer publish with rsync --delete from a CI runner. The Hugo build fix below still applies. The blog is now built on my machine and uploaded as a versioned release that the server switches to in one step; see A self-host life. Moving away from the development server My original Compose service ran: hugo: image: klakegg/hugo:latest command: server volumes: - "./2023-blog/:/src" hugo server is useful during development, but a production static site does not need a long-running Hugo process. A cleaner design is: ...

November 16, 2024

Debugging Gitea SSH across Docker and two firewalls

The failure HTTPS access to Gitea worked, but cloning over SSH from my Windows machine failed: ssh: connect to host git.example.com port 2221: Network is unreachable The repository was configured to expose the container's SSH server on host port 2221: ports: - "2221:22" The correct clone form was therefore: ssh://git@git.example.com:2221/owner/repository.git So I tested each network layer on its own. Layer 1: Is Gitea's SSH server healthy? On the server, I tested the published port through loopback: ...

November 2, 2024

Upgrading Gitea and correcting its reverse-proxy configuration

Why this was more than an image update My Gitea installation had been running version 1.18.0 for several years. Upgrading a stateful service is not equivalent to replacing a stateless web container: Gitea owns database migrations, configuration, repositories, keys, and user-generated data. Before changing the image, I backed up MariaDB and the persistent Gitea directories. I also recorded the current Compose configuration and container versions. That created both a recovery path and a baseline for post-upgrade comparison. ...

October 17, 2024

Cleaning and securing a spam-abused Gitea instance

Discovering the abuse While investigating storage growth, I found repository owners I did not recognize. Their names and repositories followed patterns common to search-engine spam: product keywords, numeric suffixes, empty projects, and matching wiki repositories. The legitimate repositories belonged to my own user. The unknown accounts had accumulated over time because the Gitea instance was publicly reachable and registration had remained enabled. This changed the task from simple disk cleanup into incident response. Removing large files was not enough; I needed to remove the application records, close the registration path, and review credentials. ...

October 3, 2024

Recovering a Docker host from a full filesystem

The symptom was not the cause My self-hosted Gitea instance started returning 502 Bad Gateway. Nginx was still answering requests, so the error only told me that its upstream service was unavailable. Before changing the reverse proxy, I checked the host: df -h The root filesystem was completely full: Filesystem Size Used Avail Use% Mounted on /dev/root 50G 48G 0 100% / A full filesystem can stop a database from writing, prevent applications from creating temporary files, and even make configuration files impossible to save. The 502 was therefore a downstream symptom of a storage incident. ...

September 20, 2024

A self-host life

Couple thoughts on self-host The idea came to me when I was exploring options to host my Hugo blog, a place for me to ramble. I needed somewhere to deploy the blog and a domain name that would remain human-readable. Then I started thinking about version control and continuous delivery. I could have put the site on an established platform and called it a day. But isn't that too simple? ...

January 9, 2023