From b4899eec303b0470e9af39c1f64c581272ccc969 Mon Sep 17 00:00:00 2001 From: jutty Date: Mon, 9 Mar 2026 14:43:39 -0300 Subject: [PATCH] Pass container scripts' parameters to podman --- containers/build.sh | 3 ++- containers/run.sh | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/containers/build.sh b/containers/build.sh index 33a5816..abd7008 100755 --- a/containers/build.sh +++ b/containers/build.sh @@ -3,6 +3,7 @@ set -eu suffix=$(printf '%s' "$1" | sed 's/.*\.//') tag="en:$suffix" +shift if podman container exists "$tag"; then podman stop --time 3 "$tag" @@ -16,7 +17,7 @@ fi podman build \ --tag "$tag" \ - -f "Containerfile.$suffix" + -f "Containerfile.$suffix" "$@" if [ -f en ]; then rm -v en diff --git a/containers/run.sh b/containers/run.sh index 784ec44..82af2d3 100755 --- a/containers/run.sh +++ b/containers/run.sh @@ -4,9 +4,12 @@ set -eu suffix=$(printf '%s' "$1" | sed 's/.*\.//') name="en-$suffix" tag="en:$suffix" +shift podman run \ --replace \ --name "$name" \ --publish 3008:80 \ + --init \ + "$@" \ "$tag"