feature/tech #3
@ -47,7 +47,7 @@ RUN cmake \
|
||||
-D MPI_BASE_DIR="/usr" \
|
||||
-C /toolsrc/Xyce/cmake/trilinos/trilinos-config-MPI.cmake \
|
||||
/toolsrc/Trilinos
|
||||
RUN cmake --build . -j 8 -t install
|
||||
RUN cmake --build . -j 40 -t install
|
||||
|
||||
# install Xyce
|
||||
WORKDIR /toolsrc
|
||||
@ -175,9 +175,12 @@ RUN mkdir /opt/cad/conf
|
||||
ENV USER "bcli"
|
||||
ENV USER_ID "1000"
|
||||
ENV GROUP_ID "1000"
|
||||
ENV MEMBERS ""
|
||||
|
||||
CMD exec /bin/bash -c "/usr/sbin/groupadd -g $GROUP_ID $USER; \
|
||||
RUN echo "HELLO!?!?"
|
||||
CMD exec /bin/bash -c "echo \"$MEMBERS\" | sed 's/ /\n/g' | xargs -n 2 /usr/sbin/groupadd -g; \
|
||||
/usr/sbin/useradd -u $USER_ID -g $USER $USER; \
|
||||
echo \"$MEMBERS\" | sed 's/ [0-9]\+ /,/g' | sed 's/[0-9]\+ //g' | xargs -I{} /usr/sbin/usermod -aG {} $USER; \
|
||||
cp -r /template /home/$USER; \
|
||||
chown -R $USER:$USER /home/$USER; \
|
||||
trap : TERM INT; sleep infinity & wait"
|
||||
|
@ -1,6 +1,7 @@
|
||||
bcli() {
|
||||
if [ "$1" = "up" ]; then
|
||||
docker run --rm -d -v $HOME:/host -v "/opt/tech:/opt/cad/conf" --name "bcli-$USER" -h "bcli-$USER" -e USER=$USER -e USER_ID=$(id -u) -e GROUP_ID=$(id -g) -e DISPLAY=$DISPLAY -v "/tmp/.X11-unix:/tmp/.X11-unix:rw" public.ecr.aws/l5h5o6z4/broccoli-cli:latest > /dev/null
|
||||
export MEMBERS="$(groups | sed 's/ /\n/g' | xargs -I{} getent group {} | sed 's/\([^:]*\):[^:]*:\([^:]*\):.*/\2 \1/g')"
|
||||
docker run --rm -d -v $HOME:/host -v "/opt/tech:/opt/cad/conf" --name "bcli-$USER" -h "bcli-$USER" -e USER=$USER -e USER_ID=$(id -u) -e GROUP_ID=$(id -g) -e DISPLAY=$DISPLAY -e MEMBERS="$MEMBERS" -v "/tmp/.X11-unix:/tmp/.X11-unix:rw" public.ecr.aws/l5h5o6z4/broccoli-cli:latest > /dev/null
|
||||
#docker run --rm -d -v $HOME:/host -v "${BCLI_TECH:/opt/tech}:/opt/cad/conf" --name "bcli-$USER" -h "bcli-$USER" -e USER=$USER -e USER_ID=$(id -u) -e GROUP_ID=$(id -g) -e DISPLAY=$DISPLAY -v "/tmp/.X11-unix:/tmp/.X11-unix:rw" ${BCLI_IMAGE:-public.ecr.aws/l5h5o6z4/broccoli-cli:latest} > /dev/null
|
||||
echo "bcli-$USER started"
|
||||
elif [ "$1" = "down" ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user