From ace880e61091bb494ae2bbaed2159ab057081135 Mon Sep 17 00:00:00 2001 From: ducoterra Date: Mon, 25 Nov 2024 23:17:25 -0500 Subject: [PATCH] add tmux --- infrastructure/graduated/fedora/Containerfile | 3 ++- infrastructure/graduated/fedora/arch-build.sh | 5 ++-- infrastructure/graduated/fedora/arch-push.sh | 6 +++++ .../graduated/fedora/fedora-kinoite.md | 26 +++++++++++++++++++ 4 files changed, 37 insertions(+), 3 deletions(-) create mode 100755 infrastructure/graduated/fedora/arch-push.sh diff --git a/infrastructure/graduated/fedora/Containerfile b/infrastructure/graduated/fedora/Containerfile index 36cd117..db8205f 100644 --- a/infrastructure/graduated/fedora/Containerfile +++ b/infrastructure/graduated/fedora/Containerfile @@ -21,7 +21,8 @@ RUN pacman -S --noconfirm \ python \ python-pip \ python-pipx \ - ansible + ansible \ + tmux # Ollama RUN curl -fsSL https://ollama.com/install.sh | sh diff --git a/infrastructure/graduated/fedora/arch-build.sh b/infrastructure/graduated/fedora/arch-build.sh index b022042..1a52a42 100755 --- a/infrastructure/graduated/fedora/arch-build.sh +++ b/infrastructure/graduated/fedora/arch-build.sh @@ -1,3 +1,5 @@ +#!/bin/bash + # Build latest image podman build \ -t gitea.reeseapps.com/services/arch-toolbox:latest \ @@ -8,5 +10,4 @@ podman container stop arch-toolbox-latest # Remove the old container podman container rm arch-toolbox-latest # Start with the new image -toolbox create -i gitea.reeseapps.com/services/arch-toolbox:latest -SHELL=/bin/zsh toolbox enter \ No newline at end of file +toolbox create -i gitea.reeseapps.com/services/arch-toolbox:latest \ No newline at end of file diff --git a/infrastructure/graduated/fedora/arch-push.sh b/infrastructure/graduated/fedora/arch-push.sh new file mode 100755 index 0000000..3ea94b4 --- /dev/null +++ b/infrastructure/graduated/fedora/arch-push.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +podman image ls \ + -f 'reference=gitea.reeseapps.com/services/arch-toolbox:latest' \ + -n --no-trunc --format '{{ .Repository }}:{{ .Tag }}' \ + | xargs -I {} podman push {} \ No newline at end of file diff --git a/infrastructure/graduated/fedora/fedora-kinoite.md b/infrastructure/graduated/fedora/fedora-kinoite.md index 1d84f47..b07b86b 100644 --- a/infrastructure/graduated/fedora/fedora-kinoite.md +++ b/infrastructure/graduated/fedora/fedora-kinoite.md @@ -236,6 +236,7 @@ I have a custom arch image based on the default arch-toolbox image. It offers: - aws cli - ollama (add `export OLLAMA_HOST=my.ollama.host` to your `.zshrc` to use a remote host) - podman (connected automatically to the host machine via the unix socket) +- tmux #### Using Reese's Arch Toolbox @@ -289,3 +290,28 @@ podman image ls \ -n --no-trunc --format '{{ .Repository }}:{{ .Tag }}' \ | xargs -I {} podman push {} ``` + +In vscode you can set this as your default build task for homelab and trigger it with +`ctrl shift B` + +.vscode/tasks.json + +```json +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "Build arch-toolbox", + "type": "shell", + "command": "./infrastructure/graduated/fedora/arch-build.sh", + "problemMatcher": [], + "group": { + "kind": "build", + "isDefault": true + } + } + ] +} +```