Commit Graph

144 Commits

Author SHA1 Message Date
stellarshenson
17d60ae85b fix: remove unsupported --no-startup flag from watchtower
nickfedor/watchtower fork doesn't have --no-startup flag.
Default behavior (without --update-on-start) is to not check on startup.
2025-12-08 17:11:31 +01:00
stellarshenson
d46e0c1c28 chore: bump version to 3.3.4 2025-12-08 17:08:48 +01:00
stellarshenson
65e0f96abd chore: update version comment to reflect 3.3.x features 2025-12-08 17:07:34 +01:00
stellarshenson
6328ffbc65 chore: bump version to 3.3.3 with watchtower fix 2025-12-08 17:06:56 +01:00
stellarshenson
861ea0cd8c fix: prevent watchtower from checking images on container restart
Added --no-startup flag to Watchtower command in compose.yml.
Previously, Watchtower would check for image updates on every container
startup/restart. Now only runs at scheduled time (midnight daily).
2025-12-08 17:06:23 +01:00
stellarshenson
25efd91bb6 docs: clarify GPU detection uses separate container in journal
Updated journal entry #16 to specify nvidia/cuda container spawning.
Version bump: 3.3.2 -> 3.3.3
2025-12-04 19:10:37 +01:00
stellarshenson
dea9e75fbb chore: cleanup startup scripts and bump version to 3.3.2
Removed obsolete 01_nvidia-smi.sh (GPU detection handled in jupyterhub_config.py).
Renamed 02_ensure_groups.py to 01_ensure_groups.py for sequential ordering.
2025-12-04 19:01:11 +01:00
stellarshenson
2ced4851c8 chore: add compose_override.yml to gitignore 2025-11-27 00:03:02 +01:00
stellarshenson
9357d8bdd6 chore: update watchtower to maintained fork (nickfedor/watchtower)
Changed from containrrr/watchtower:latest to nickfedor/watchtower:latest.
New image is actively maintained and compatible with latest Docker versions.

Version bump: 3.2.11 -> 3.3.1
2025-11-27 00:00:36 +01:00
stellarshenson
d8bf7fb67b docs: add paypal donation badge 2025-11-15 17:38:14 +00:00
stellarshenson
af15336364 docs: update badges with github actions, jupyterlab 4, and kolomolo branding 2025-11-13 15:55:56 +00:00
stellarshenson
dacb0ee223 chore: update journal with volume architecture diagram work 2025-11-12 11:47:10 +00:00
stellarshenson
8f2670eb39 docs: add note about user volume reset capability 2025-11-12 11:46:12 +00:00
stellarshenson
5954db2ef0 docs: improve arrow alignment for shared volume in diagram 2025-11-12 11:42:42 +00:00
stellarshenson
01ddabf9ee fix: represent /mnt/shared as single shared resource across containers 2025-11-12 11:40:54 +00:00
stellarshenson
18de422fea docs: show multiple users sharing jupyterhub_shared volume in diagram 2025-11-12 11:40:02 +00:00
stellarshenson
f01aa75979 docs: simplify user container label in volume diagram 2025-11-12 11:39:25 +00:00
stellarshenson
57be9a0911 fix: escape underscores in volume architecture diagram node IDs 2025-11-12 11:36:21 +00:00
stellarshenson
2380c33252 docs: add volume architecture diagram
Added Volume Architecture diagram showing four persistent volumes per user with Docker host to container mount mapping. Diagram illustrates jupyterlab-{username}_* naming pattern for user-specific volumes (home, workspace, cache) and shared jupyterhub_shared volume. Shows mount points and example contents for each volume type, with note about CIFS mount capability for NAS integration.
2025-11-12 11:35:55 +00:00
stellarshenson
b10b685138 docs: add configuration flow, gpu auto-detection, and user workflow diagrams
Added three mermaid diagrams to README documenting system architecture and workflows. Configuration Flow diagram shows how environment variables from compose.yml flow through jupyterhub_config.py to spawned user containers, including DOCKER_SPAWNER_VOLUMES, VOLUME_DESCRIPTIONS, BUILTIN_GROUPS, pre_spawn_hook, extra_handlers, and template_paths. GPU Auto-Detection diagram illustrates the auto-detect mechanism with temporary CUDA container spawning nvidia-smi for detection. User Self-Service Workflow diagram demonstrates home page state management for restart server and manage volumes features. Converted HTML alert divs to GitHub-style WARNING blocks for better rendering.
2025-11-12 10:48:56 +00:00
stellarshenson
8e3315eff2 chore: enhanced gitignore to encompass more 2025-11-12 09:57:23 +00:00
stellarshenson
ca9f163365 updated gitignore 2025-11-12 00:32:31 +00:00
stellarshenson
9d0c04562a doc: updated links in the README 2025-11-11 17:49:34 +00:00
stellarshenson
2d84024624 docs: update journal and clarify docker-privileged group in README
Added journal entry #13 documenting release v3.2.11 preparation:
- Git tag creation with annotations
- RELEASE.md delta notes
- Documentation simplification (docker-socket-permissions.md from 66 to 19 lines)
- project.env update with release metadata
- Security warning corrections (host system -> Docker host)
- HTML alert styling for warnings

Updated README.md to explicitly name 'docker-privileged' group in opening
description of privileged access section for clarity.
2025-11-10 00:19:21 +01:00
stellarshenson
d0de218074 docs: fix docker.sock security warnings and add alert styling
Corrected security warnings to accurately describe docker.sock access:
- Changed 'host system' to 'Docker host' (docker.sock grants access to Docker
  daemon, not physical host system)
- Applied warning alert style (alert-block alert-warning) to security notes in
  README.md for better visibility

Updated in:
- README.md: Two security warnings (Requirements section, Privileged Access)
- doc/docker-socket-permissions.md: Security note
- .claude/CLAUDE.md: Security warning

Security warnings now use HTML alert boxes for emphasis and accurate terminology.
2025-11-10 00:18:10 +01:00
stellarshenson
1f0adb7308 release 2025-11-09 23:09:42 +01:00
stellarshenson
bd1b676a2f chore: update project.env for RELEASE_3.2.11
Updated version metadata:
- VERSION_COMMENT reflects key features of v3.2.11
- Added RELEASE_TAG: RELEASE_3.2.11
- Added RELEASE_DATE: 2025-11-09

This marks the official release of version 3.2.11 with configuration-agnostic
volume management, notification broadcast, and privileged access control.
2025-11-09 23:04:20 +01:00
stellarshenson
522403f89d docs: further simplify docker-socket-permissions.md
Reduced from 66 to 19 lines focusing on essentials:
- Simplified pre-spawn hook code
- Built-in group mechanism
- Admin panel management
- Security warning

Removed verbose explanations, use cases, auditing commands.
2025-11-09 23:02:20 +01:00
stellarshenson
d230f45bfe docs: update RELEASE.md for v3.2.11
Delta release notes covering changes from v3.0.14 to v3.2.11:
- Configuration-agnostic volume management with optional descriptions
- Admin notification broadcast system
- Privileged user docker.sock access control
- Documentation following modus primaris style
- Technical improvements and upgrade notes

Following modus primaris: concise, factual, organized sections.
2025-11-09 22:55:59 +01:00
stellarshenson
a018c7f506 docs: update journal with configuration-agnostic volume management
Added entry #12 documenting volume management refactoring to be fully
configuration-agnostic with optional descriptions, import error fixes for
jupyterhub_config.py, and README/documentation simplification following
modus primaris style.
RELEASE_3.2.11
2025-11-09 22:51:33 +01:00
stellarshenson
12953ee4d6 feat: add optional volume descriptions for UI
Added VOLUME_DESCRIPTIONS config dict allowing optional user-friendly
descriptions for volumes shown in management UI.

Changes:
- Added VOLUME_DESCRIPTIONS dict in jupyterhub_config.py (optional, co-defined
  with DOCKER_SPAWNER_VOLUMES)
- Exposed volume_descriptions via c.JupyterHub.template_vars
- Updated home.html to conditionally display descriptions if defined
- If volume not in VOLUME_DESCRIPTIONS, no description shown (UI remains agnostic)

Configuration example:
VOLUME_DESCRIPTIONS = {
    'home': 'User home directory files, configurations',
    'workspace': 'Project files, notebooks, code',
    'cache': 'Temporary files, pip cache, conda cache'
}

Documentation:
- Updated .claude/CLAUDE.md with Manage Volumes implementation details
- Simplified Restart Server section for consistency
- Added template variables to doc/ui-template-customization.md

UI now shows volume name, Docker volume path, and optional description
(if configured). Fully backward compatible - descriptions are optional.
2025-11-09 22:50:13 +01:00
stellarshenson
96f3d546b0 fix: protect jupyterhub_config.py from import errors
Fixed NameError when custom_handlers.py imports from jupyterhub_config.py
by protecting all c.* assignments with 'if c is not None:' checks.

Changes:
- Wrapped c = get_config() in try-except to handle module import context
- Defined DOCKER_SPAWNER_VOLUMES as module-level constant
- Modified get_user_volume_suffixes() to accept volumes dict parameter
- USER_VOLUME_SUFFIXES calculated from constant (importable without c defined)
- Protected all c.* configuration assignments with 'if c is not None:' guards

This allows custom_handlers.py to import USER_VOLUME_SUFFIXES without
triggering "NameError: name 'get_config' is not defined" when the config
file is imported as a module rather than loaded by JupyterHub.

Volume management now works correctly - configuration can be safely imported
by handlers to validate volume names against USER_VOLUME_SUFFIXES.
2025-11-09 22:39:59 +01:00
stellarshenson
d03ad7be22 feat: make volume management UI configuration-agnostic
Updated volume management to dynamically read volume names from
DockerSpawner.volumes configuration instead of hardcoding them:

- Added get_user_volume_suffixes() function to extract volume suffixes from
  config matching jupyterlab-{username}_<suffix> pattern
- Exposed USER_VOLUME_SUFFIXES via c.JupyterHub.template_vars for templates
- Updated home.html to use Jinja2 loop generating checkboxes dynamically
  from user_volume_suffixes variable
- Modified ManageVolumesHandler to validate against configured volumes
  instead of hardcoded {'home', 'workspace', 'cache'}
- Removed volume descriptions (e.g., "Contains: User home directory...") to
  keep UI truly agnostic

Now works correctly if volumes are renamed, added, or removed in configuration
without requiring template or handler changes. Volume names displayed exactly
as defined in config (home, workspace, cache by default).
2025-11-09 22:36:22 +01:00
stellarshenson
28cb8098dc docs: simplify architecture diagram labels
Condensed verbose diagram labels following modus primaris:
- "NativeAuthenticator User Management" -> "NativeAuthenticator"
- "User: alice" -> "alice"
- "alice_home/alice_workspace/alice_cache" -> "Volumes home/workspace/cache"
- "jupyterhub_shared CIFS/NAS Optional" -> "Shared Storage CIFS/NAS"
- Removed verbose edge labels (|Mounts|, |Shared|) for cleaner flow

Diagram remains clear while reducing visual noise and text verbosity.
2025-11-09 22:28:51 +01:00
stellarshenson
cc124e2a3a docs: simplify notification broadcast feature description
Condensed verbose notification broadcast description to essential facts:
- Admin broadcast capability
- Route location (/hub/notifications)
- Six notification types
- 140-character limit
- Extension dependency

Reduced from 3 sentences to 2 short sentences following modus primaris brevity.
2025-11-09 22:28:12 +01:00
stellarshenson
3516be1f63 docs: reorganize README structure with features first, modus primaris style
Restructured README.md following modus primaris approach:
1. Simplified intro (one concise paragraph)
2. Features as bullet points at top
3. User Interface screenshots (with explanations before images)
4. Architecture diagram and explanation
5. Remaining sections (References, Requirements, Quickstart, etc.)

Removed duplicate Features and User Interface sections that were previously
positioned after Architecture. Content now flows logically from high-level
features to visual examples to technical architecture details.
2025-11-09 22:26:43 +01:00
stellarshenson
6cfd8a9af5 docs: reorganize README screenshots with explanations before images
Reordered User Interface section:
- Home control panel (server restart and volume management)
- Volume management screenshots grouped together
- Admin notification broadcast (last)

Changed format: explanation text with heading before each screenshot image,
replacing italic captions below images for better readability.
2025-11-09 22:25:11 +01:00
stellarshenson
47b4bd094c docs: update journal entry to reflect minimal documentation style
Updated entry #11 to accurately reflect the super-minimal modus primaris style
approach with line counts for each documentation file (35, 55, 66 lines) and
emphasis on "glimpse of implementation" rather than comprehensive coverage.
2025-11-09 22:24:23 +01:00
stellarshenson
7ba01412d1 docs: simplify documentation to minimal modus primaris style
Drastically reduced documentation length focusing only on essential
implementation facts:

- doc/notifications.md: Reduced from 250 to 35 lines - key technical facts,
  handler implementation, template details, dependencies, error handling
- doc/ui-template-customization.md: Reduced from 132 to 55 lines - technical
  facts, JavaScript patterns, Bootstrap 5 syntax, CSRF protection, build process
- doc/docker-socket-permissions.md: Reduced from 186 to 66 lines - implementation
  facts, pre-spawn hook code, built-in group system, security implications, usage

All documentation now follows super-minimal "glimpse of implementation" approach
with bullet points and code snippets, absent of lengthy narrative and marketing
language.
2025-11-09 22:23:54 +01:00
stellarshenson
f1dcf61db7 docs: update journal with documentation and screenshots entry
Added entry #11 documenting comprehensive documentation creation for
notification system, UI customization, and Docker socket permissions. Also
documented screenshot updates in README.md replacing restart server image with
complete control panel view and adding admin notification broadcast interface.
2025-11-09 22:21:18 +01:00
stellarshenson
9eda62edd7 docs: add comprehensive documentation and update screenshots
Added three new documentation files following modus primaris style:
- doc/ui-template-customization.md: Guide for extending JupyterHub UI
  templates with RequireJS, Bootstrap 5, CSRF protection, and custom handlers
- doc/docker-socket-permissions.md: Docker socket access control documentation
  covering group-based permissions, security implications, and best practices
- doc/notifications.md: Complete notification broadcast system documentation
  including implementation details, API integration, error handling, and
  troubleshooting

Updated UI screenshots in README.md:
- Replaced screenshot-restart-server.png with screenshot-home.png showing
  complete user control panel (restart server + volume management)
- Added screenshot-send-notification.png showing admin notification broadcast
  interface with message composer, type selector, and delivery results

All documentation follows consistent structure: brief overview, key facts in
bullet points, explanatory narrative, and technical specifications without
excessive nesting or marketing language.
2025-11-09 22:20:28 +01:00
stellarshenson
c6dfe89c84 docs: update CLAUDE.md with accurate notification system details
Updated notification broadcast system documentation in .claude/CLAUDE.md to
reflect actual implementation details:

- Corrected message character limit from 500 to 140 characters
- Updated notification type list to include all 6 types (default, info, success,
  warning, error, in-progress) instead of just 4
- Clarified authentication mechanism: temporary token generation with 5-minute
  expiry via user.new_api_token() rather than retrieving existing tokens
- Fixed endpoint URL pattern showing correct base_url interpolation
- Corrected extension endpoint path (hyphen not underscore)
- Added Dismiss button feature to UI features list
- Updated error handling to include HTTP 500 and logging details
- Added explanation of one-line logging per server delivery

These changes ensure the embedded configuration accurately documents the
notification broadcast feature as implemented in version 3.2.0.
2025-11-09 22:17:38 +01:00
stellarshenson
0e39fac7ac feat: add admin notification broadcast system for active JupyterLab servers
Implemented comprehensive notification broadcast functionality allowing
administrators to send notifications to all active user JupyterLab servers
simultaneously through a dedicated admin panel.

Core Features:
- Admin-only notification panel accessible at /hub/notifications
- Concurrent delivery to all active servers using asyncio with 5s timeout
- Temporary API token generation (5-minute expiry) for authentication
- Support for 6 notification types: default, info, success, warning, error, in-progress
- 140-character message limit with live character counter
- Auto-close toggle and dismiss button in notifications
- Dynamic endpoint URL construction using spawner.server.base_url
- Comprehensive error handling with user-friendly messages
- One-line logging per server with message preview and outcome

Technical Implementation:
- Created BroadcastNotificationHandler in custom_handlers.py
- Created NotificationsPageHandler for admin UI rendering
- Added notifications.html template with Bootstrap 5 form
- Registered handlers in jupyterhub_config.py extra_handlers
- Sends to /jupyterlab-notifications-extension/ingest endpoint
- Payload includes type, message, autoClose, and actions array
- Navigation link added to home.html for admin access

Integration:
- Requires jupyterlab_notifications_extension installed on JupyterLab servers
- Uses correct payload format (type field, not variant)
- Includes Dismiss action button for manual notification closure

Documentation:
- Updated .claude/CLAUDE.md with complete feature documentation
- Updated README.md Features section with notification broadcast details
- Updated .claude/JOURNAL.md with implementation summary
- Removed obsolete FEATURE_PLAN.md

Version: 3.2.0 (bumped from 3.1.2)
2025-11-09 22:05:06 +01:00
stellarshenson
067b613397 feat: add group-based docker.sock access control for privileged users
Implemented built-in protected group system enabling admins to grant trusted users read-write Docker socket access within their JupyterLab containers. Groups are managed through admin panel and cannot be permanently deleted.
RELEASE_3.1.2
2025-11-05 20:15:30 +01:00
stellarshenson
f126571fb2 docs: update journal with production readiness work
- Document visual enhancements with Font Awesome icons
- Note GitHub Actions CI/CD implementation
- Record architecture diagram addition to README
- Document critical custom_handlers import fix
- Note built-in config feature
- Record git history cleanup (removed co-authoring)
- Version progression 3.0.20 -> 3.0.23
2025-11-04 23:33:49 +01:00
stellarshenson
09e69e9467 fix: prevent Docker Compose from pulling image after build
- Add pull_policy: build to jupyterhub service
- Forces Docker Compose to use locally built image
- Prevents unnecessary pulls from Docker Hub after building

Now 'docker compose up' will use the local image built with 'make build'
2025-11-04 23:30:22 +01:00
stellarshenson
db483de36d feat: build jupyterhub_config.py into Docker image by default
- Change Docker build context from services/jupyterhub to project root
- Copy config/jupyterhub_config.py into image at /srv/jupyterhub/jupyterhub_config.py
- Users can still override with volume mount if needed
- Update all COPY paths in Dockerfile to reflect new build context
- Enables container to work out-of-the-box without external config file

Benefits:
- Image is self-contained and ready to run without dependencies
- Volume mount remains optional for custom configurations
- Default config includes GPU auto-detection and self-service features
2025-11-04 23:25:17 +01:00
stellarshenson
e8bf0b7c54 updated 2025-11-04 23:20:46 +01:00
stellarshenson
e985786499 fix: add /srv/jupyterhub to Python path for custom_handlers import
- Add /srv/jupyterhub to sys.path before importing custom_handlers
- Separate shell scripts and Python files in Dockerfile COPY commands
- Resolves ModuleNotFoundError for custom_handlers module
- JupyterHub now starts successfully with custom API handlers
RELEASE_3.0.21 STABLE_3.0.21_cuda-12.9.1_jh-5.4.2
2025-11-04 11:06:25 +01:00
stellarshenson
274237ee7c docs: remove fill colors from architecture diagram for transparent background
- Remove fill colors from mermaid diagram nodes
- Keep stroke colors and widths for visual distinction
- Improves compatibility with different GitHub themes (light/dark mode)
2025-11-04 10:54:10 +01:00