Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set usage_mode #106

Merged
merged 1 commit into from
Oct 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 @@
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
Comment on lines +118 to +119
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does setup.sh get run after this?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes.

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
Loading