Skip to content
Snippets Groups Projects
Commit b85e0fd2 authored by Sylvester Joosten's avatar Sylvester Joosten
Browse files

Added container shell wrapper to setup release container

parent 5e2ac09d
Branches
Tags
1 merge request!3v2.0.1
......@@ -26,10 +26,12 @@ COPY --from=builder /opt/view /opt/view
COPY --from=builder /etc/profile.d/z10_spack_environment.sh /etc/profile.d/z10_spack_environment.sh
## Setup global bashrc, useful for singularity
COPY --from=builder /root/.bashrc /etc/bash.bashrc
COPY eic-shell /usr/local/bin/eic-shell
COPY --from=builder /etc/profile.d/z10_spack_environment.sh /etc/eic-env.sh
## make sure we have the entrypoints setup correctly
ENTRYPOINT []
CMD ["bash", "--rcfile", "/etc/profile", "-l"]
USER 0
WORKDIR /
SHELL ["bash", "--rcfile", "/etc/profile"]
SHELL ["/usr/local/bin/eic-shell"]
#! /usr/bin/env bash
source /etc/profile
if [ -p /dev/stdin ]; then
# If we want to read the input line by line
while IFS= read line; do
if [ -z "$piped_args" ]; then
piped_args="${line}"
else
piped_args="${piped_args}\n${line}"
fi
done
fi
## Fire off bash
if [ ${piped_args} ] ; then
echo -e ${piped_args} | exec bash
elif [ $# -gt 0 ]; then
exec bash -c "$@"
else
exec bash
fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment