Category: devops

  • Moving from Docker volumes to bind mounts

    When I started with Docker, the docs seemed to suggest that using Docker volumes was a good thing. With a Docker volume, you just create the volume and Docker manages the rest. You don’t have to worry about where it is, or really ever think about it. Here’s a docker-compose for Uptime Kuma using a…

  • dockerfile – CMD vs ENTRYPOINT

    There are two entries we often have at the end of a dockerfile (which is the file that tells Docker how an image is to be built). They are similar in that when the container is launched from an image, these commands will be executed. For example, both of the dockerfiles below will print “Hello…

  • User environment variables are not available in cron

    I’m used to using the docker-compose.yaml or dockerfile to set environment variables for containers running my apps, but ran into an issue recently where the variable seemed to be set some of the time, but at others it didn’t appear to exist. I had a script set to run by cron inside the container, and…

  • SSH login notification

    My VPS’s are usually locked down so just ports 80 & 443 (for web server) and 22 (for ssh) are open. That’s great for reducing the attack surface, but having ssh open is a potentially disastrous vulnerability. For this reason I often close that at the cloud firewall level as well, but it has to…

  • Upgrading to Forgejo 7.0.1

    It’s not that long ago that I wrote about doing routine upgrades on containerised web apps using Forgejo as an example as I upgraded Forgejo (my git repository manager) between patch versions of 1.21, then a few days later, they dropped 7.0.0 They say the major version jump is due to it being an LTS…

  • Peek inside a Docker image

    A ‘dockerfile’ contains all the instructions to build a Docker image. Here’s my first draft for a project I’m working on: COPY . . is copying all of the files in my project into the working directory of the image so they can be run. Of course we don’t need them all for the app…

  • NGINX Proxy Manager

    I’ve mentioned using NGINX as an interface between the internet and a service a while ago. This works by all incoming traffic coming to NGINX, and NGINX determining which service that traffic should go (from the NGINX config files) then acting as a middleman. This functionality is generally referred to as a ‘reverse proxy’. This…

  • My Web App Update Process

    I’ve settled on a very standard, reproducible setup for services in my homelab. This post looks at that, then runs through the update I did today to Forgejo which only took a few minutes and felt relatively risk free. Standard Setups My system is based around Proxmox. I have three physical machines – one for…

  • Deploying a Node app in Docker

    When I wrote the install instructions for mdserver (little Markdown server Node app) on it’s github page it was something like: Which is great if you know how to do those things (they are bread and butter to a web dev) but not if you’re a self-hoster who just wants a web server that converts…

  • Hosting Your Own Docker Registry

    The Docker Personal (ie free tier) plan currently allows one private repository, but even if you want to pay for the next level where you can have unlimited repositories, you may still want to host your own private registry – it’s going to be quicker inside your network, and you won’t run up against Docker’s…