This repository has been archived by the owner on Aug 9, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34 from jamesbeedy/slurm_config_editor_preparation Summary of Changes: - improve the way slurmd sends slurmctld its partition and node parameter options - add an action, node-config to get and set unit-level node-configuration - add partition-config charm configuration that allows an operator to set - partition configuration - consolidate the yaml files into charmcraft.yaml - remove unused code - remove slurm-ops-manager - replace nhc resource with nhc in build process in charmcraft.yaml - remove dependencies on slurmdbd BREAKING CHANGES: No longer compatible with the old Slurm charm API. Charms will need to be tested locally as the charms in the edge branch on CharmHub are not compatible with the new API version.
- Loading branch information
Showing
30 changed files
with
2,736 additions
and
1,205 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,11 @@ | ||
#!/bin/bash | ||
# This hook installs the dependencies needed to run the charm, | ||
# creates the dispatch executable, regenerates the symlinks for start and | ||
# upgrade-charm, and kicks off the operator framework. | ||
|
||
set -e | ||
|
||
# Source the os-release information into the env | ||
. /etc/os-release | ||
|
||
if ! [[ -f '.installed' ]] | ||
then | ||
if [[ $ID == 'centos' ]] | ||
then | ||
# Install dependencies and build custom python | ||
yum -y install epel-release | ||
yum -y install wget gcc make tar bzip2-devel zlib-devel xz-devel openssl-devel libffi-devel sqlite-devel ncurses-devel | ||
|
||
export PYTHON_VERSION=3.8.16 | ||
wget https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz -P /tmp | ||
tar xvf /tmp/Python-${PYTHON_VERSION}.tar.xz -C /tmp | ||
cd /tmp/Python-${PYTHON_VERSION} | ||
./configure --enable-optimizations | ||
make -C /tmp/Python-${PYTHON_VERSION} -j $(nproc) altinstall | ||
cd $OLDPWD | ||
rm -rf /tmp/Python* | ||
|
||
elif [[ $ID == 'ubuntu' ]] | ||
then | ||
# Necessary to compile and install NHC | ||
apt-get install --assume-yes make | ||
fi | ||
touch .installed | ||
fi | ||
|
||
# set the correct python bin path | ||
if [[ $ID == "centos" ]] | ||
then | ||
PYTHON_BIN="/usr/bin/env python3.8" | ||
else | ||
PYTHON_BIN="/usr/bin/env python3" | ||
# Necessary to compile and install NHC | ||
apt-get install --assume-yes make | ||
touch .installed | ||
fi | ||
|
||
JUJU_DISPATCH_PATH="${JUJU_DISPATCH_PATH:-$0}" PYTHONPATH=lib:venv $PYTHON_BIN ./src/charm.py | ||
JUJU_DISPATCH_PATH="${JUJU_DISPATCH_PATH:-$0}" PYTHONPATH=lib:venv /usr/bin/env python3 ./src/charm.py |
Oops, something went wrong.