JupyterHub SLURM Spawner with specific spawn page
Project description
jupyterhub_moss: JupyterHub MOdular Slurm Spawner
This package extends batchspawner.SlurmSpawner
to provide a JupyterHub Slurm Spawner with a spawn page allowing to select Slurm resources to use.
Example
jupyterhub_conf.py
:
import batchspawner
import jupyterhub_moss
c = get_config()
# Init JupyterHub configuration to use this spawner
jupyterhub_moss.set_config(c)
# Partition descriptions
c.MOSlurmSpawner.partitions = {
"partition_1": { # Partition name
"description": "Partition 1", # Displayed description
"architecture": "x86_86", # Nodes architecture
"gpu": None, # --gres= template to use for requesting GPUs
"simple": True, # True to show in Simple tab
"venv": "/jupyter_env_path/bin/", # Path to Python environment bin/ used to start jupyter on the Slurm nodes
"max_ngpus": 0, # Maximum number of GPUs per node
"max_nprocs": 28, # Maximum number of CPUs per node
},
"partition_2": {
"description": "Partition 2",
"architecture": "ppc64le",
"gpu": "gpu:V100-SXM2-32GB:{}",
"simple": True,
"venv": "/path/to/jupyter/env/for/partition_2/bin/",
"max_ngpus": 2,
"max_nprocs": 128,
},
"partition_3": {
"description": "Partition 3",
"architecture": "x86_86",
"gpu": None,
"simple": False,
"venv": "/path/to/jupyter/env/for/partition_3/bin/",
"max_ngpus": 0,
"max_nprocs": 28,
},
}
Build package from source
Pre-requisite: pip install build
From the project directory, run: python3 -m build
to generate the wheel and tarball in dist/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
jupyterhub_moss-1.0.1.tar.gz
(10.4 kB
view hashes)
Built Distribution
Close
Hashes for jupyterhub_moss-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e32291f42cb43620de00da87dc7bc9f2a344d8c87f6e2d8ee814adf4d6dee2c1 |
|
MD5 | 0d71b1ae0a8caba8f46c53d86b79e07b |
|
BLAKE2b-256 | b6ff78551fcee5ddc345ee9362e99e36578c74cae216008270136ee561228a14 |