Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
eic_container
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
containers
eic_container
Merge requests
!107
Resolve "eic-shell --upgrade"
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Resolve "eic-shell --upgrade"
70-eic-shell-upgrade
into
master
Overview
0
Commits
2
Pipelines
0
Changes
1
Merged
Sylvester Joosten
requested to merge
70-eic-shell-upgrade
into
master
3 years ago
Overview
0
Commits
2
Pipelines
0
Changes
1
Expand
Closes
#70 (closed)
Edited
3 years ago
by
Sylvester Joosten
0
0
Merge request reports
Compare
master
version 1
014b1aa2
3 years ago
master (base)
and
latest version
latest version
b4c2696f
2 commits,
3 years ago
version 1
014b1aa2
1 commit,
3 years ago
1 file
+
72
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
install.sh
+
72
−
0
Options
@@ -185,6 +185,78 @@ done
## that sets the ATHENA_PREFIX and then starts singularity
cat
<<
EOF
> eic-shell
#!/bin/bash
## capture environment setup for upgrades
CONTAINER=
$CONTAINER
TMPDIR=
$TMPDIR
VERSION=
$VERSION
PREFIX=
$PREFIX
DISABLE_CVMFS_USAGE=
${
DISABLE_CVMFS_USAGE
}
function print_the_help {
echo "USAGE: ./eic-shell [OPTIONS]"
echo "OPTIONAL ARGUMENTS:"
echo " -u,--upgrade Upgrade the container to the latest version"
echo " -n,--no-cvmfs Disable check for local CVMFS when updating. (D: enabled)"
echo " -h,--help Print this message"
echo ""
echo " Start the eic-shell containerized software environment."
echo ""
echo "EXAMPLE: ./eic-shell"
exit
}
UPGRADE=
while [
\$
# -gt 0 ]; do
key=
\$
1
case
\$
key in
-u|--upgrade)
UPGRADE=1
shift
;;
-n|--no-cvmfs)
DISABLE_CVMFS_USAGE=true
shift
;;
-h|--help)
print_the_help
exit 0
;;
*)
echo "ERROR: unknown argument:
\$
key"
echo "use --help for more info"
exit 1
;;
esac
done
if [ ! -z
\$
{UPGRADE} ]; then
echo "Upgrading eic-shell..."
if [ -z "
\$
DISABLE_CVMFS_USAGE" -a -d /cvmfs/singularity.opensciencegrid.org/eicweb/
\$
{CONTAINER}:
\$
{VERSION} ]; then
echo ""
echo "Note: You cannot manually update the container as you are using the CVMFS version."
echo " The container will automatically update every 24 hours."
echo " You can override this by setting the '--no-cvmfs' flag, which will"
echo " instantiate a local version."
echo " This is only recommended for expert usage."
echo ""
echo "Exiting without upgrade"
exit 0
fi
FLAGS="-p
\$
{PREFIX} -v
\$
{VERSION}"
if [ ! -z
\$
{TMPDIR} ]; then
FLAGS="
\$
{FLAGS} -t
\$
{TMPDIR}"
fi
if [ ! -z
\$
{DISABLE_CVMFS_USAGE} ]; then
FLAGS="
\$
{FLAGS} --no-cvmfs"
fi
curl https://eicweb.phy.anl.gov/containers/eic_container/-/raw/master/install.sh
\
| bash -s --
\$
{FLAGS}
echo "eic-shell upgrade sucessful"
exit 0
fi
export ATHENA_PREFIX=
$PREFIX
/local
export SINGULARITY_BINDPATH=
$BINDPATH
$SINGULARITY
exec
$SIF
eic-shell
Loading