Skip to content

Commit

Permalink
set usage_mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Tianhao-Gu committed Oct 15, 2024
1 parent e35b8c4 commit bb860f2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/jupyterhub_config/custom_docker_spawner.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ def _configure_environment(self, user_dir: Path, user_env_dir: Path, username: s
self.log.info(f'MinIO read/write user detected: {self.user.name}. Setting up minio_rw credentials.')
self.environment['MINIO_ACCESS_KEY'] = self.environment['MINIO_RW_ACCESS_KEY']
self.environment['MINIO_SECRET_KEY'] = self.environment['MINIO_RW_SECRET_KEY']
# USAGE_MODE is used by the setup.sh script to determine the appropriate configuration for the user.
self.environment['USAGE_MODE'] = 'dev'

Check warning on line 119 in src/jupyterhub_config/custom_docker_spawner.py

View check run for this annotation

Codecov / codecov/patch

src/jupyterhub_config/custom_docker_spawner.py#L119

Added line #L119 was not covered by tests
else:
self.log.info(f'Non-admin user detected: {self.user.name}. Removing admin credentials.')
self.environment.pop('MINIO_RW_ACCESS_KEY', None)
Expand Down

0 comments on commit bb860f2

Please sign in to comment.