Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jupyter-jsc-custom
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
jupyterjsc
packages
jupyter-jsc-custom
Commits
4390e1a7
Commit
4390e1a7
authored
1 month ago
by
Tim Kreuzer
Browse files
Options
Downloads
Patches
Plain Diff
add denbiCloud Check
parent
a4830879
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
jsc_custom/handler/share_handler.py
+10
-3
10 additions, 3 deletions
jsc_custom/handler/share_handler.py
with
10 additions
and
3 deletions
jsc_custom/handler/share_handler.py
+
10
−
3
View file @
4390e1a7
...
...
@@ -9,6 +9,7 @@ from jupyterhub.handlers.pages import SpawnHandler
from
jupyterhub.utils
import
url_path_join
from
tornado
import
web
from
..misc
import
get_custom_config
from
..orm.share
import
UserOptionsShares
...
...
@@ -160,8 +161,6 @@ class R2DHandler(SpawnHandler):
"
urlpath
"
)[
0
].
decode
(
"
utf-8
"
)
# https://jupyter-jsc-dev2.fz-juelich.de/hub/r2d/gh/FZJ-JSC/jupyter-jsc-notebooks
# Get System
auth_state
=
await
user
.
get_auth_state
()
if
len
(
arguments_dict_lower
.
get
(
"
system
"
,
[]))
>
0
:
...
...
@@ -169,6 +168,14 @@ class R2DHandler(SpawnHandler):
elif
len
(
auth_state
.
get
(
"
outpost_flavors
"
,
{}).
keys
())
>
0
:
system
=
list
(
auth_state
.
get
(
"
outpost_flavors
"
,
{}).
keys
())[
0
]
else
:
try
:
custom_config
=
get_custom_config
()
if
"
deNBI-Cloud
"
in
custom_config
.
get
(
"
systems
"
,
{}).
keys
():
system
=
"
deNBI-Cloud
"
else
:
system
=
"
JSC-Cloud
"
except
:
self
.
log
.
exception
(
"
Could not check for systems
"
)
system
=
"
JSC-Cloud
"
user_options
[
"
system
"
]
=
system
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment