Skip to main content

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


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.0.tar.gz (10.5 kB view details)

Uploaded Source

Built Distribution

jupyterhub_moss-1.0.0-py3-none-any.whl (11.2 kB view details)

Uploaded Python 3

File details

Details for the file jupyterhub_moss-1.0.0.tar.gz.

File metadata

  • Download URL: jupyterhub_moss-1.0.0.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.5.0.1 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

File hashes

Hashes for jupyterhub_moss-1.0.0.tar.gz
Algorithm Hash digest
SHA256 bc22e5cfebb4834f33e9e350aadceb184cf3d9d186a5de8d2049c32c4bffb9f4
MD5 eaed03ae9882c39f4bb9387f880dd836
BLAKE2b-256 f171fe6013326a7dc06baa3881cae38f6b8775520c6468f3719b4c5452512342

See more details on using hashes here.

File details

Details for the file jupyterhub_moss-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: jupyterhub_moss-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 11.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.5.0.1 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

File hashes

Hashes for jupyterhub_moss-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 08a5ba38404b0fe1d66e2d49a3c285f08009b24086e20a687d332c98ee70f09c
MD5 d2c596b6debc2a66416784cefe5a558a
BLAKE2b-256 513acd1e4e412d73b3872252159ae97e97f1af4c8c1e5ddcfc4d0bf644d58002

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page