Skip to content

vantagecompute/slurm-factory

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

41 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Vantage Compute Logo

Slurm Factory

License Python PyPI Docker

Build relocatable, GPG-signed Slurm packages using Docker and Spack.

Documentation | Buildcache

Quick Start

Option 1: Install Pre-built Slurm from Buildcache (Fastest!)

Use Spack to install GPG-signed pre-built binaries (no slurm-factory tool needed):

# Install Spack
git clone --depth 1 --branch v1.0.0 https://github.com/spack/spack.git
source spack/share/spack/setup-env.sh

# Add mirrors for compilers, dependencies, and Slurm
SLURM_VERSION=25.11
COMPILER_VERSION=15.2.0
CLOUDFRONT_URL=https://slurm-factory-spack-binary-cache.vantagecompute.ai

spack mirror add slurm-factory-build-toolchain "${CLOUDFRONT_URL}/compilers/${COMPILER_VERSION}"
spack mirror add slurm-factory-slurm-deps "${CLOUDFRONT_URL}/deps/${COMPILER_VERSION}"
spack mirror add slurm-factory-slurm "${CLOUDFRONT_URL}/slurm/${SLURM_VERSION}/${COMPILER_VERSION}"

# Import GPG keys and install Slurm (5-15 min!)
spack buildcache keys --install --trust
spack install slurm@${SLURM_VERSION}%gcc@${COMPILER_VERSION}

β†’ Full guide: Installing Slurm from Buildcache

Option 2: Build Custom Slurm with slurm-factory Tool

Install the slurm-factory tool to build custom packages:

# Install Docker and the slurm-factory build tool
pip install slurm-factory

# Build Slurm with default compiler (GCC 13.4.0)
slurm-factory build-slurm --slurm-version 25.11

β†’ Full guide: Installing slurm-factory Tool

Supported Versions

Slurm Γ— Operating System Matrix

All combinations use OS-provided compilers and are available in the public buildcache:

Slurm Version Status Supported Operating Systems
25.11 Latest Rocky 10, Rocky 9, Rocky 8, Ubuntu 24.04, Ubuntu 22.04, Ubuntu 25.04
24.11 LTS Rocky 10, Rocky 9, Rocky 8, Ubuntu 24.04, Ubuntu 22.04, Ubuntu 25.04
23.11 Stable Rocky 10, Rocky 9, Rocky 8, Ubuntu 24.04, Ubuntu 22.04, Ubuntu 25.04

Default: Ubuntu 24.04 (Noble) - recommended for most users

Operating System Compiler Toolchains

Slurm is built using the default system compiler from each OS distribution:

OS Codename GCC Version GLIBC Use Case
Ubuntu 24.04 Noble 13.2.0 2.39 Recommended - Modern stable
Ubuntu 25.04 Resolute 15.2.0 2.42 Latest features (development)
Ubuntu 22.04 Jammy 11.4.0 2.35 LTS - Wide compatibility
Rocky Linux 10 - 14.2.1 2.40 RHEL 10 compatible
Rocky Linux 9 - 11.4.1 2.34 RHEL 9 compatible
Rocky Linux 8 - 8.5.0 2.28 RHEL 8 compatible

GPG Package Signing

All packages are cryptographically signed with GPG for security and integrity.

Why GPG Signing?

  • βœ… Authenticity: Verify packages were built by Vantage Compute
  • βœ… Integrity: Detect tampering or corruption during download
  • βœ… Security: Prevent man-in-the-middle attacks
  • βœ… Trust Chain: Establish provenance for production deployments

GPG Key Information

Key ID: DFB92630BCA5AB71
Owner: Vantage Compute Corporation (Slurm Factory Spack Cache Signing Key)
Email: [email protected]

Importing GPG Keys

Keys are automatically imported when using the buildcache:

# Automatic import and trust
spack buildcache keys --install --trust

# Packages are verified during installation
spack install [email protected]%[email protected]

Features

  • πŸ” GPG-Signed Packages - All Slurm packages cryptographically signed
  • ⚑ 10-15x Faster - Pre-built packages install in 5-15 minutes vs 45-90 minutes
  • πŸ“¦ Relocatable - Deploy to any path, no host dependencies
  • 🌍 CDN Distribution - CloudFront-distributed buildcache for fast global access
  • 🐧 6 OS Platforms - Rocky Linux 8/9/10, Ubuntu 22.04/24.04/25.04
  • 🎯 3 Slurm Versions - 25.11, 24.11, 23.11
  • 🏭 OS-Native Compilers - Uses system-provided GCC for maximum compatibility
  • πŸš€ Optimized - Architecture-specific compilation (x86_64_v3)
  • 🐳 Clean Builds - Docker isolation, no system pollution

Build Options

Build from Source with slurm-factory

# Default build (CPU-only, Ubuntu 24.04 toolchain)
slurm-factory build-slurm --slurm-version 25.11

# GPU support (CUDA/ROCm)
slurm-factory build-slurm --slurm-version 25.11 --gpu

# Different OS toolchain
slurm-factory build-slurm --slurm-version 25.11 --toolchain jammy

# Build and publish to buildcache with GPG signing
slurm-factory build-slurm --slurm-version 25.11 --publish \
  --signing-key $GPG_KEY_ID \
  --gpg-private-key "$GPG_PRIVATE_KEY" \
  --gpg-passphrase "$GPG_PASSPHRASE"

Install Pre-built from Buildcache (Fastest!)

# Install Spack
git clone --depth 1 --branch v1.0.0 https://github.com/spack/spack.git
source spack/share/spack/setup-env.sh

# Configure mirrors for buildcache
SLURM_VERSION=25.11
TOOLCHAIN=noble  # or: jammy, rockylinux9, etc.
CLOUDFRONT_URL=https://slurm-factory-spack-binary-cache.vantagecompute.ai

spack mirror add slurm-factory-slurm-deps "${CLOUDFRONT_URL}/deps/${TOOLCHAIN}"
spack mirror add slurm-factory-slurm "${CLOUDFRONT_URL}/slurm/${SLURM_VERSION}/${TOOLCHAIN}"

# Import GPG signing keys and trust
spack buildcache keys --install --trust

# Install signed package (5-15 minutes!)
spack install slurm@${SLURM_VERSION} target=x86_64_v3

# Deploy
spack load slurm@${SLURM_VERSION}

Download Pre-built Tarball (Alternative)

Download complete Slurm installation as a tarball with GPG signature verification:

# Set versions
SLURM_VERSION=25.11
TOOLCHAIN=noble  # or: jammy, rockylinux9, etc.
CLOUDFRONT_URL=https://slurm-factory-spack-binary-cache.vantagecompute.ai

# Download tarball and signature
wget "${CLOUDFRONT_URL}/builds/${SLURM_VERSION}/${TOOLCHAIN}/slurm-${SLURM_VERSION}-${TOOLCHAIN}-software.tar.gz"
wget "${CLOUDFRONT_URL}/builds/${SLURM_VERSION}/${TOOLCHAIN}/slurm-${SLURM_VERSION}-${TOOLCHAIN}-software.tar.gz.asc"

# Import GPG key
gpg --keyserver keyserver.ubuntu.com --recv-keys DFB92630BCA5AB71

# Verify signature
gpg --verify slurm-${SLURM_VERSION}-${TOOLCHAIN}-software.tar.gz.asc \
             slurm-${SLURM_VERSION}-${TOOLCHAIN}-software.tar.gz

# Extract and install
sudo tar -xzf slurm-${SLURM_VERSION}-${TOOLCHAIN}-software.tar.gz -C /opt/
cd /opt && sudo ./data/slurm_assets/slurm_install.sh --full-init

Package Structure

All builds produce GPG-signed relocatable tarballs:

slurm-25.11-noble-software.tar.gz
β”œβ”€β”€ view/                    # Slurm binaries & libraries
β”œβ”€β”€ modules/slurm/25.11.lua  # Lmod module (relocatable)
└── data/slurm_assets/       # Config templates & install script

Deployment

# Extract (from tarball build)
sudo tar -xzf slurm-25.11-noble-software.tar.gz -C /opt/

# Install (creates users, configs, services)
cd /opt && sudo ./data/slurm_assets/slurm_install.sh --full-init

# Use
module load slurm/25.11

Buildcache Structure

The public buildcache is organized by OS toolchain for optimal performance:

https://slurm-factory-spack-binary-cache.vantagecompute.ai/
β”œβ”€β”€ deps/
β”‚   β”œβ”€β”€ rockylinux10/    # Slurm dependencies for Rocky Linux 10 (GPG-signed)
β”‚   β”œβ”€β”€ rockylinux9/     # Slurm dependencies for Rocky Linux 9 (GPG-signed)
β”‚   β”œβ”€β”€ rockylinux8/     # Slurm dependencies for Rocky Linux 8 (GPG-signed)
β”‚   β”œβ”€β”€ jammy/           # Slurm dependencies for Ubuntu 22.04 (GPG-signed)
β”‚   β”œβ”€β”€ noble/           # Slurm dependencies for Ubuntu 24.04 (GPG-signed)
β”‚   └── resolute/        # Slurm dependencies for Ubuntu 25.04 (GPG-signed)
β”œβ”€β”€ slurm/
β”‚   β”œβ”€β”€ 25.11/
β”‚   β”‚   β”œβ”€β”€ rockylinux10/ # Slurm 25.11 for Rocky Linux 10 (GPG-signed)
β”‚   β”‚   β”œβ”€β”€ rockylinux9/ # Slurm 25.11 for Rocky Linux 9 (GPG-signed)
β”‚   β”‚   β”œβ”€β”€ rockylinux8/ # Slurm 25.11 for Rocky Linux 8 (GPG-signed)
β”‚   β”‚   β”œβ”€β”€ jammy/       # Slurm 25.11 for Ubuntu 22.04 (GPG-signed)
β”‚   β”‚   β”œβ”€β”€ noble/       # Slurm 25.11 for Ubuntu 24.04 (GPG-signed)
β”‚   β”‚   └── resolute/    # Slurm 25.11 for Ubuntu 25.04 (GPG-signed)
β”‚   β”œβ”€β”€ 24.11/
β”‚   β”‚   └── ...          # All OS toolchains (GPG-signed)
β”‚   └── 23.11/
β”‚       └── ...          # All OS toolchains (GPG-signed)
└── builds/
    β”œβ”€β”€ 25.11/
    β”‚   β”œβ”€β”€ rockylinux10/
    β”‚   β”‚   β”œβ”€β”€ slurm-25.11-rockylinux10-software.tar.gz      # Complete tarball
    β”‚   β”‚   └── slurm-25.11-rockylinux10-software.tar.gz.asc  # GPG signature
    β”‚   β”œβ”€β”€ noble/
    β”‚   β”‚   β”œβ”€β”€ slurm-25.11-noble-software.tar.gz
    β”‚   β”‚   └── slurm-25.11-noble-software.tar.gz.asc
    β”‚   └── ...          # All OS toolchains
    β”œβ”€β”€ 24.11/
    β”‚   └── ...
    └── 23.11/
        └── ...

Mirror Architecture

The buildcache uses a two-tier mirror structure for efficient caching and dependency resolution:

  1. deps/ - Slurm runtime dependencies (OpenMPI, PMIx, Munge, etc.) per OS toolchain
  2. slurm/ - Slurm packages compiled with OS-native compilers

This separation allows:

  • βœ… Better caching - Dependencies shared across Slurm versions
  • βœ… Reduced storage - No duplication of common packages
  • βœ… Parallel downloads - Spack can fetch from multiple mirrors simultaneously
  • βœ… OS compatibility - Packages built with native system compilers

Requirements

  • Python 3.12+
  • Docker 24.0+ (for building from source)
  • 50GB disk space
  • 4+ CPU cores (8+ recommended)
  • 16GB RAM (32GB+ recommended)

For buildcache installs: only Spack required (no Docker needed)

Documentation

vantagecompute.github.io/slurm-factory

Development

# Install from source
git clone https://github.com/vantagecompute/slurm-factory.git
cd slurm-factory
pip install -e .

# Run tests
pytest

# Build docs
cd docusaurus && npm run build

License

Apache License 2.0 - See LICENSE file.

Support


Built with ❀️ by Vantage Compute