summaryrefslogtreecommitdiff
path: root/rushmore-linux/rl-docker.sh
diff options
context:
space:
mode:
Diffstat (limited to 'rushmore-linux/rl-docker.sh')
-rwxr-xr-xrushmore-linux/rl-docker.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/rushmore-linux/rl-docker.sh b/rushmore-linux/rl-docker.sh
new file mode 100755
index 0000000..af278b7
--- /dev/null
+++ b/rushmore-linux/rl-docker.sh
@@ -0,0 +1,17 @@
+#!/usr/bin/env bash
+set -euo pipefail
+
+DIR="$(cd "$(dirname "$0")" && pwd)"
+IMG="rl-kernel-builder:ubuntu24.04"
+
+if ! docker image inspect "$IMG" > /dev/null 2>&1; then
+ echo "Docker image $IMG not found, building..."
+ docker build -t "$IMG" -f Dockerfile .
+fi
+
+if [ "$#" -eq 0 ]; then
+ echo "Usage: $0 <script> [args...]"
+ exit 1
+fi
+
+docker run --rm -it -v "$DIR:/work" -w /work "$IMG" bash -lc "$*" \ No newline at end of file