From 0397174460cd56b53113bdce903c519cd0a028c7 Mon Sep 17 00:00:00 2001 From: Job79 Date: Sun, 8 Nov 2026 11:31:01 +0100 Subject: [PATCH] refactor(base): set environment via ENV instead of bashrc Variables in .bashrc only reached interactive shells, so commands started with DEVC_COMMAND or a plain podman exec missed them. Also disable the Claude auto-updater, as /usr/local/bin is not writable and the image is rebuilt weekly. Co-Authored-By: Claude Opus 5.5 --- containers/base/Containerfile | 8 ++++++++ containers/base/config/bashrc | 9 ++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/containers/base/Containerfile b/containers/base/Containerfile index 3f31add..e674b2c 100644 --- a/containers/base/Containerfile +++ b/containers/base/Containerfile @@ -19,6 +19,14 @@ RUN LAZYGIT_VERSION=$(curl -s "https://api.github.com/repos/jesseduffield/lazygi COPY ./bin /usr/local/bin +# === environment === +ENV EDITOR=nvim \ + TZ=Europe/Amsterdam \ + XDG_RUNTIME_DIR=/run/user/1000 \ + WAYLAND_DISPLAY=wayland-0 \ + SSH_AUTH_SOCK=/run/user/1000/ssh-auth-sock \ + DISABLE_AUTOUPDATER=1 + # === setup user === RUN useradd -ms /bin/bash user && \ echo 'user ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/user && \ diff --git a/containers/base/config/bashrc b/containers/base/config/bashrc index 18e74db..c4cd2bb 100644 --- a/containers/base/config/bashrc +++ b/containers/base/config/bashrc @@ -1,12 +1,7 @@ source /etc/bashrc -# === environment === -export PS1="\[\e[30;46m\] \h | \w \[\e[0;36m\]\[\e[m\] " \ - EDITOR="nvim" \ - WAYLAND_DISPLAY="wayland-0" \ - XDG_RUNTIME_DIR="/run/user/1000" \ - SSH_AUTH_SOCK="/run/user/1000/ssh-auth-sock" \ - TZ="Europe/Amsterdam" +# === prompt === +export PS1="\[\e[30;46m\] \h | \w \[\e[0;36m\]\[\e[m\] " # === aliases and functions === alias vi=nvim