-
Notifications
You must be signed in to change notification settings - Fork 0
/
GPSC_SETUP.bash
38 lines (31 loc) · 1.36 KB
/
GPSC_SETUP.bash
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# @file SETUP.bash
# @brief Source this file to add the Portage Cluster Utils tools to your PATH in place.
#
# GPSC psub initialization
#
#
# @author Marc Tessier
#
# Traitement multilingue de textes / Multilingual Text Processing
# Technologies numériques / Digital Technologies
# Conseil national de recherches Canada / National Research Council Canada
# Copyright 2024, Sa Majeste le Roi du Chef du Canada /
# Copyright 2024, His Majesty the King in Right of Canada
#Set to your assigned project name
export PSUB_PROJECT_NAME=nrc_ict
echo "PortageClusterUtils, NRC-CNRC, (c) 2005 - 2024, His Majesty the King in Right of Canada" >&2
SOURCE="${BASH_SOURCE[0]}"
if [[ -h $SOURCE ]]; then
SOURCE=$(readlink -f $SOURCE)
fi
BASE_DIR="$( cd "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )"
echo "PortageClusterUtils path: $BASE_DIR" >&2
export PATH=$BASE_DIR/bin:$PATH
# Set default container OS.
if grep "CentOS Linux release 7" /etc/centos-release >& /dev/null; then
export PSUB_RES_IMAGE=${PSUB_RES_IMAGE_OVERRIDE:-nrc/nrc_all_default_centos-7-amd64_latest}
elif grep "Ubuntu 20" /etc/os-release >& /dev/null; then
export PSUB_RES_IMAGE=${PSUB_RES_IMAGE_OVERRIDE:-nrc/nrc_all_default_ubuntu-20.04-amd64_latest}
elif grep "Ubuntu 22" /etc/os-release >& /dev/null; then
export PSUB_RES_IMAGE=${PSUB_RES_IMAGE_OVERRIDE:-nrc/nrc_all_default_ubuntu-22.04-amd64_latest}
fi