Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F4017339
D2369.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D2369.diff
View Options
diff --git a/contrib/arc b/contrib/arc
--- a/contrib/arc
+++ b/contrib/arc
@@ -12,6 +12,8 @@
# Image: nasqueron/arcanist
# -------------------------------------------------------------
+BASE_IMAGE=nasqueron/arcanist
+
# -------------------------------------------------------------
# Parse arguments
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -53,7 +55,7 @@
BUILD_DIR=$(mktemp -d -t arc-build-XXXXXXXXXX)
pushd "$BUILD_DIR" > /dev/null || exit 1
>&2 echo "🔨 Building user-specific image $IMAGE for $USER"
- echo "FROM nasqueron/arcanist" > Dockerfile
+ echo "FROM $BASE_IMAGE" > Dockerfile
echo "RUN groupadd -r $USER -g $GID && mkdir /home/$USER && useradd -u $UID -r -g $USER -d /home/$USER -s /bin/bash $USER && cp /root/.bashrc /home/$USER/ && chown -R $USER:$USER /home/$USER && ln -s /opt/config/gitconfig /home/$USER/.gitconfig && ln -s /opt/config/arcrc /home/$USER/.arcrc" >> Dockerfile
docker build -t "$IMAGE" .
popd > /dev/null
@@ -64,10 +66,10 @@
test -v $GID && GID=$(id -g)
if [ $UID -eq 0 ]; then
- IMAGE=nasqueron/arcanist
+ IMAGE=$BASE_IMAGE
CONTAINER_USER_HOME=/root
else
- IMAGE=nasqueron/arcanist:$UID-$GID
+ IMAGE=$BASE_IMAGE:$UID-$GID
test ! -z $(docker images -q "$IMAGE") || build_user_image
CONTAINER_USER_HOME="/home/$USER"
fi
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jan 19, 03:55 (20 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2359920
Default Alt Text
D2369.diff (1 KB)
Attached To
Mode
D2369: Be more flexible with Docker image selection
Attached
Detach File
Event Timeline
Log In to Comment