File tree 4 files changed +28
-68
lines changed
4 files changed +28
-68
lines changed Original file line number Diff line number Diff line change 8
8
# Source the os-release information into the env
9
9
. /etc/os-release
10
10
11
+ # set the default python bin path
12
+ PYTHON_BIN=" /usr/bin/env python3"
13
+
11
14
if ! [[ -f ' .installed' ]]
12
15
then
13
-
14
- # Rocky specific setup
15
- if [[ $ID == ' rocky' ]]
16
- then
17
- dnf install epel-release -y
18
- dnf install dnf-plugins-core -y
19
- dnf config-manager --set-enabled powertools -y
20
- fi
21
-
22
- if [[ $ID == ' centos' || $ID == ' rocky' ]]
16
+ if [[ $ID == ' centos' ]]
23
17
then
24
18
# Install dependencies
25
19
yum -y install epel-release
37
31
cd $OLDPWD
38
32
rm -rf /tmp/Python*
39
33
40
- # set the correct python bin path
34
+ # set the custom python bin path
41
35
PYTHON_BIN=" /opt/python/python3.8/bin/python3.8"
42
36
elif [[ $ID == ' ubuntu' ]]
43
37
then
44
38
# Necessary to compile and install NHC
45
- apt-get install --assume-yes make
46
-
47
- # set the correct python bin path
48
- PYTHON_BIN=" /usr/bin/env python3"
39
+ apt-get install --assume-yes make
49
40
fi
50
41
51
42
touch .installed
52
43
fi
53
44
54
-
55
- JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
45
+ JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
Original file line number Diff line number Diff line change 8
8
# Source the os-release information into the env
9
9
. /etc/os-release
10
10
11
+ # set the default python bin path
12
+ PYTHON_BIN=" /usr/bin/env python3"
13
+
11
14
if ! [[ -f ' .installed' ]]
12
15
then
13
-
14
- # Rocky specific setup
15
- if [[ $ID == ' rocky' ]]
16
- then
17
- dnf install epel-release -y
18
- dnf install dnf-plugins-core -y
19
- dnf config-manager --set-enabled powertools -y
20
- fi
21
-
22
- if [[ $ID == ' centos' || $ID == ' rocky' ]]
16
+ if [[ $ID == ' centos' ]]
23
17
then
24
18
# Install dependencies
25
19
yum -y install epel-release
37
31
cd $OLDPWD
38
32
rm -rf /tmp/Python*
39
33
40
- # set the correct python bin path
34
+ # set the custom python bin path
41
35
PYTHON_BIN=" /opt/python/python3.8/bin/python3.8"
42
36
elif [[ $ID == ' ubuntu' ]]
43
37
then
44
38
# Necessary to compile and install NHC
45
- apt-get install --assume-yes make
46
-
47
- # set the correct python bin path
48
- PYTHON_BIN=" /usr/bin/env python3"
39
+ apt-get install --assume-yes make
49
40
fi
50
41
51
42
touch .installed
52
43
fi
53
44
54
-
55
- JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
45
+ JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
Original file line number Diff line number Diff line change 8
8
# Source the os-release information into the env
9
9
. /etc/os-release
10
10
11
+ # set the default python bin path
12
+ PYTHON_BIN=" /usr/bin/env python3"
13
+
11
14
if ! [[ -f ' .installed' ]]
12
15
then
13
-
14
- # Rocky specific setup
15
- if [[ $ID == ' rocky' ]]
16
- then
17
- dnf install epel-release -y
18
- dnf install dnf-plugins-core -y
19
- dnf config-manager --set-enabled powertools -y
20
- fi
21
-
22
- if [[ $ID == ' centos' || $ID == ' rocky' ]]
16
+ if [[ $ID == ' centos' ]]
23
17
then
24
18
# Install dependencies
25
19
yum -y install epel-release
37
31
cd $OLDPWD
38
32
rm -rf /tmp/Python*
39
33
40
- # set the correct python bin path
34
+ # set the custom python bin path
41
35
PYTHON_BIN=" /opt/python/python3.8/bin/python3.8"
42
36
elif [[ $ID == ' ubuntu' ]]
43
37
then
44
38
# Necessary to compile and install NHC
45
- apt-get install --assume-yes make
46
-
47
- # set the correct python bin path
48
- PYTHON_BIN=" /usr/bin/env python3"
39
+ apt-get install --assume-yes make
49
40
fi
50
41
51
42
touch .installed
52
43
fi
53
44
54
-
55
- JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
45
+ JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
Original file line number Diff line number Diff line change 8
8
# Source the os-release information into the env
9
9
. /etc/os-release
10
10
11
+ # set the default python bin path
12
+ PYTHON_BIN=" /usr/bin/env python3"
13
+
11
14
if ! [[ -f ' .installed' ]]
12
15
then
13
-
14
- # Rocky specific setup
15
- if [[ $ID == ' rocky' ]]
16
- then
17
- dnf install epel-release -y
18
- dnf install dnf-plugins-core -y
19
- dnf config-manager --set-enabled powertools -y
20
- fi
21
-
22
- if [[ $ID == ' centos' || $ID == ' rocky' ]]
16
+ if [[ $ID == ' centos' ]]
23
17
then
24
18
# Install dependencies
25
19
yum -y install epel-release
37
31
cd $OLDPWD
38
32
rm -rf /tmp/Python*
39
33
40
- # set the correct python bin path
34
+ # set the custom python bin path
41
35
PYTHON_BIN=" /opt/python/python3.8/bin/python3.8"
42
36
elif [[ $ID == ' ubuntu' ]]
43
37
then
44
38
# Necessary to compile and install NHC
45
- apt-get install --assume-yes make
46
-
47
- # set the correct python bin path
48
- PYTHON_BIN=" /usr/bin/env python3"
39
+ apt-get install --assume-yes make
49
40
fi
50
41
51
42
touch .installed
52
43
fi
53
44
54
-
55
- JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
45
+ JUJU_DISPATCH_PATH=" ${JUJU_DISPATCH_PATH:- $0 } " PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py
You can’t perform that action at this time.
0 commit comments