From 80ab8355dd52f3d6aa6eaaa99423de4a42135b9d Mon Sep 17 00:00:00 2001 From: Tamipes Date: Mon, 12 Jan 2026 22:52:48 +0100 Subject: [PATCH] doc: add README.md --- .gitignore | 1 + README.md | 26 ++++++++++++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 .gitignore create mode 100644 README.md diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b2be92b --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +result diff --git a/README.md b/README.md new file mode 100644 index 0000000..1b53f56 --- /dev/null +++ b/README.md @@ -0,0 +1,26 @@ +This repository is just a for auto updating the default `nix` docker image for forgejo runner on my instance. + +# Setup: +As you cannot run a forgejo runner with `nixos/nix` due to it not having `node` by default, you need to manually build and upload the first image. After that you can specify your instance's image as a base image for forgejo runner. + +### Manual upload of the first image: +```bash + USERNAME="tamipes" + URL="git.tami.moe" + nix build --extra-experimental-features "flakes nix-command" . + docker login "https://$URL" + docker load -i result + docker image tag nix "$URL/$USERNAME/nix:latest" + docker push "$URL/$username/nix" + + # I also tag with the date, but this might be unneeded + docker image tag nix "$URL/$USERNAME/nix:latest$(date --iso-8601)" + docker push "$URL/$username/nix" +``` + + +# Extra info +- This image is essentially still "based" on `nixos/nix`, but it builds it with nodejs included. Checkout the flake.nix! + - it does not use `nixos/nix` as a base image, but uses the same build script and adds extra stuff + - [nixpkgs manual](https://nix.dev/manual/nix/2.24/installation/installing-docker#docker-image-with-the-latest-development-version-of-nix) + - [nixos/nix build script](https://github.com/NixOS/nix/blob/master/docker.nix)