Skip to content

Tresillo2017/slurm-manager

Repository files navigation

SLURM Manager icon

SLURM Manager

SSH-based HPC job monitor and controller for Android

Android Kotlin Jetpack Compose Material 3 License Release

SLURM Manager connects to one or more HPC clusters over SSH and lets you monitor, filter, and control Slurm jobs directly from your phone or tablet. No VPN client or web portal required — just an SSH key or password.


Screenshots

Phone

Home screen Job detail Servers Server detail Settings / About

Tablet

Home screen (tablet) Servers (tablet) Settings (tablet)

Medium tablet

Home screen (medium tablet) Server detail (medium tablet) Settings (medium tablet)


Features

  • Multi-cluster support — add as many servers as you need; switch with a single filter chip
  • Live job list — background polling via WorkManager keeps the job list fresh
  • Job detail — resources, timeline, runtime, and one-tap cancel / requeue
  • Job submission — pick a local sbatch script or type one inline, set partition / nodes / CPUs / time limit
  • Alert rules — per-server threshold alerts for queue wait time, runtime exceeded, node failures, and partition down events
  • Push notifications — state-change and threshold alerts delivered as Android notifications (with progress indicators for running jobs)
  • Adaptive layout — two-pane list-detail on tablets and large phones; bottom nav on compact; rail on medium
  • Material You — full dynamic color (Android 12+) with expressive spring motion
  • SSH auth — password or private key (Ed25519, RSA, ECDSA); private keys stored in EncryptedSharedPreferences

Architecture

app/src/main/java/com/tomasps/slurmmanager/
├── data/
│   ├── credential/      EncryptedSharedPreferences key store
│   ├── local/db/        Room database — Job + Server entities, DAOs
│   ├── notification/    NotificationEngine (state-change + alert notifications)
│   ├── remote/ssh/      SshClient (sshj), SlurmOutputParser (squeue output → domain models)
│   ├── repository/      JobRepositoryImpl, ServerRepositoryImpl
│   └── worker/          PollWorker (WorkManager), AlertEngine, JobDiffer
├── di/                  Hilt modules (AppModule, DataStoreModule, WorkerModule)
├── domain/
│   ├── model/           Job, Server, JobState, AlertRule, AlertType, AuthMethod, …
│   └── repository/      JobRepository, ServerRepository interfaces
└── presentation/
    ├── dashboard/        Job list with server filter chips, FAB, pull-to-refresh
    ├── jobdetail/        Resources, timeline, cancel/requeue actions
    ├── onboarding/       Add-server wizard with connection test
    ├── serverdetail/     Per-server jobs, history, polling/alert settings
    ├── servers/          Server list with swipe-to-delete
    ├── settings/         Global notification + appearance preferences
    ├── submit/           Modal bottom sheet for sbatch job submission
    ├── navigation/       NavigationSuiteScaffold + NavGraph with shared-axis transitions
    └── theme/            SlrumManagerTheme (dynamic color, MotionScheme.expressive())

Stack summary:

Layer Technology
UI Jetpack Compose + Material 3 Expressive
Navigation Navigation Compose 2.9 with NavigationSuiteScaffold
State ViewModel + StateFlow
DI Hilt 2.56
Local DB Room 2.7
Preferences Jetpack DataStore
Secure storage androidx-security-crypto (EncryptedSharedPreferences)
Background work WorkManager 2.10
SSH sshj 0.38 + BouncyCastle 1.78 (full, not Android-stripped)
Serialization kotlinx.serialization 1.8

Requirements

Android 11+ (API 30)
Target SDK 36
Cluster Any host running Slurm with an SSH daemon
Auth Password or private key (Ed25519 / RSA / ECDSA)

Building

  1. Clone the repo:

    git clone https://github.com/Tresillo2017/slurm-manager.git
    cd slurm-manager
  2. Open in Android Studio Meerkat (2025.1) or later.

  3. Build and run on a device or emulator (API 30+):

    ./gradlew :app:assembleDebug

No API keys or local secrets are required — the app connects exclusively to servers you add.


Adding a server

  1. On first launch, the onboarding wizard starts automatically.
  2. Enter hostname, port (default 22), and username.
  3. Choose Password or SSH Key authentication.
    • For SSH Key: tap Import Private Key and select your .pem / private key file.
  4. Tap Test Connection — the app runs a live SSH handshake.
  5. Tap Save Server on success.

Additional servers can be added at any time from the Servers screen → + button.


Polling & alerts

Polling is done via a WorkManager periodic task scheduled per server. The interval is configurable per server (1–60 minutes) from the server detail screen.

Alert rules are also per-server and support:

Alert type Trigger
QUEUE_WAIT_EXCEEDED Job pending longer than threshold
RUNTIME_EXCEEDED Job running longer than threshold
JOB_FAILED Job transitions to FAILED / CANCELLED
NODE_FAILURE Node reports down in sinfo
PARTITION_DOWN Partition reports down in sinfo

Contributing

Pull requests are welcome. For large changes, open an issue first to discuss what you'd like to change.

# Run unit tests
./gradlew :app:test

# Run instrumented tests (requires a connected device/emulator)
./gradlew :app:connectedAndroidTest

License

MIT © Tomás Palma

About

Android app to monitor and control Slurm HPC jobs over SSH — Material You, live polling, alerts, and job submission

Topics

Resources

License

Stars

1 star

Watchers

0 watching

Forks

Sponsor this project

 

Packages

 
 
 

Contributors

Languages