Skip to content

Commit

Permalink
add alice context
Browse files Browse the repository at this point in the history
  • Loading branch information
jblomer committed Nov 16, 2016
1 parent a98e4e0 commit d0903e2
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 0 deletions.
36 changes: 36 additions & 0 deletions alice.context
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#!/bin/sh.after
parents=$(pid=$$; while [ $pid -ne 1 ]; do pid=$(ps -o ppid= -p $pid); cat /proc/$(echo $pid)/cmdline; done)
if ! echo $parents | grep -q amiconfig; then
echo "Skipping startup script, which should only run under amiconfig daemon"
exit 0
fi

ls /cvmfs/alice.cern.ch >/dev/null
echo 'if [ "$PS1" ]; then
if [ "x$CERNVM_ALICE_ENV" = "x" ]; then
. /cvmfs/alice.cern.ch/etc/login.sh || true
export CERNVM_ALICE_ENV=1
fi
fi' >> /home/alice/.bashrc
exit 0

[amiconfig]
plugins=cernvm

[cernvm]
organisations=ALICE
repositories=alice,alice-ocdb,grid,sft
shell=/bin/bash
config_url=http://cernvm.cern.ch/config
users=alice:alice:alice
edition=Desktop
screenRes=1280x700
keyboard=us
startXDM=on
auto_login=on

[ucernvm-begin]
cvmfs_branch=cernvm-sl7.cern.ch
cvmfs_server=hepvm.cern.ch
cvmfs_path=cvm4
[ucernvm-end]
1 change: 1 addition & 0 deletions atlas.context
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ fi

. /etc/cernvm/site.conf
echo "alias setupATLAS='source \${ATLAS_LOCAL_ROOT_BASE}/user/atlasLocalSetup.sh'" > /etc/profile.d/asetup.sh
ls /cvmfs/atlas.cern.ch >/dev/null
exit 0

[amiconfig]
Expand Down
1 change: 1 addition & 0 deletions lhcb.context
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ if ! echo $parents | grep -q amiconfig; then
exit 0
fi

ls /cvmfs/lhcb.cern.ch >/dev/null
echo 'if [ "$PS1" ]; then
if [ "x$CERNVM_LHCB_ENV" = "x" ]; then
. /cvmfs/lhcb.cern.ch/etc/login.sh || true
Expand Down

0 comments on commit d0903e2

Please sign in to comment.