From 6822d69ce996468e0e71281dedfbb9da07afd992 Mon Sep 17 00:00:00 2001 From: Ilias Romanos Date: Sat, 16 Nov 2024 20:30:35 +0100 Subject: [PATCH] Added diffutils and a basic README file --- Containerfile | 5 +++-- README.md | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+), 2 deletions(-) create mode 100644 README.md diff --git a/Containerfile b/Containerfile index 86e53ec..9d83871 100644 --- a/Containerfile +++ b/Containerfile @@ -30,6 +30,7 @@ COPY files/vscode.repo /etc/yum.repos.d/ # # bind-utils - for basic DNS troubleshooting # code - VS Code +# diffutils - diff tools # direnv - for managing dev environment variables # helix - modern text editor # make - for running make tasks @@ -43,6 +44,6 @@ COPY files/vscode.repo /etc/yum.repos.d/ # rcm - managing dotfiles # tmux - managing screen sessions # -RUN dnf install -y bind-utils code direnv helix make man-db pass pinentry poetry pre-commit pwgen python3-lsp-server \ - rcm tmux && \ +RUN dnf install -y bind-utils code diffutils direnv helix make man-db pass pinentry poetry pre-commit pwgen \ + python3-lsp-server rcm tmux && \ dnf clean all diff --git a/README.md b/README.md new file mode 100644 index 0000000..a2f8549 --- /dev/null +++ b/README.md @@ -0,0 +1,47 @@ +# My Dev Toolbox + +> This image is meant to be used with the toolbox-create(1) command. + +Since I started using [Fedora Silverblue] I've switched my workflow to use toolbox to set up my dev environments, +instead of overlaying packages, trying to keep my deployments as clean as possible. + +As I was learing my ways around it, I kept having to re-create my toolboxes and had to run multiple commands everytime +to set them up as I wanted it to. + +Eventually, I wrote a bash script, which worked fine. + +But recently I came across the **Custom Images** section of the [Toolbx Documentation], where it describes how one can +go on to create their own custom Toolbx image and use that. + +This repo is set up to track my Containerfile of my custom image for dev work, as well as notes and scripts related to +it. + +The relevant GitHub Actions were set up in order to build a new image everytime my Containerfile, or the files in the +`files` directory change. + +## Versioning + +The latest version of image _should_ always be available as `ghcr.io/elromanos/dev-toolbox:latest`. + +A cron job is defined to run and update it once a week, with the latest Fedora repo updates. The tag for such images is +set as **YY.WW** where **YY** is the last two digits of the year and **WW** the week number it was build. + +## Setup + +In order for the custom image to be loaded by default when I create a new toolbox, I need to override toolbox's default +settings. To do so, I had to create the `~/.config/containers/toolbox.conf` file with the following TOML content: + +```toml +[general] +image = "ghcr.io/elromanos/dev-toolbox" +``` + +## F.A.Q. + +- **Q: Why Podman and not Docker?** A: [Fedora Silverblue] comes with Podman pre-installed. As I want to keep my base + image as close to the defaults as possible, I decided to keep using Podman. For the simple needs of this exercise, + Docker and Podman __should__ be interchangable/compatible. + +[Fedora Silverblue]: https://fedoraproject.org/atomic-desktops/silverblue/ +[Toolbx Documentation]: https://containertoolbx.org/doc/ +[Red Hat Actions]: https://github.com/redhat-actions