Skip to content

Commit 8a07268

Browse files
committed
Remove PANEL_OAUTH_SCOPE and add login-endpoint
1 parent ed9b4f9 commit 8a07268

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

.envrc.example

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
export PANEL_OAUTH_REDIRECT_URI=http://localhost:5006/app
2+
export PANEL_OAUTH_KEY=
3+
export PANEL_OAUTH_SECRET=
4+
export PANEL_OAUTH_ENCRYPTION=
5+
export PANEL_TOKEN=

Makefile

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,14 @@ serve-dev: ## Serve Panel dashboard - Dev mode
4848
--reuse-sessions --warm
4949

5050
serve-oauth: ## Serve Panel dashboard - Prod mode with OAuth2. Needs: PANEL_OAUTH_REDIRECT_URI, PANEL_OAUTH_KEY, PANEL_OAUTH_SECRET, PANEL_OAUTH_ENCRYPTION
51-
PANEL_OAUTH_SCOPE=email panel serve panel/simdec_app.py panel/sampling.py \
51+
panel serve panel/simdec_app.py panel/sampling.py \
5252
--index panel/index.html \
5353
--show \
5454
--cookie-secret panel_cookie_secret_oauth \
5555
--basic-login-template panel/login.html \
5656
--logout-template panel/logout.html \
5757
--oauth-provider custom_google \
58+
--login-endpoint app \
5859
--static-dirs _static=docs/_static \
5960
--reuse-sessions --warm
6061

@@ -73,7 +74,6 @@ run-local: build-local
7374
--memory=1g \
7475
--cpuset-cpus=0 \
7576
-e ENV=development \
76-
-e PANEL_OAUTH_SCOPE=email \
7777
-e PANEL_OAUTH_REDIRECT_URI=$(PANEL_OAUTH_REDIRECT_URI) \
7878
-e PANEL_OAUTH_SECRET=$(PANEL_OAUTH_SECRET) \
7979
-e PANEL_OAUTH_KEY=$(PANEL_OAUTH_KEY) \
@@ -95,7 +95,6 @@ run: build
9595
--memory=1g \
9696
--cpuset-cpus=0 \
9797
-e ENV=development \
98-
-e PANEL_OAUTH_SCOPE=email \
9998
-e PANEL_OAUTH_REDIRECT_URI=$(PANEL_OAUTH_REDIRECT_URI) \
10099
-e PANEL_OAUTH_SECRET=$(PANEL_OAUTH_SECRET) \
101100
-e PANEL_OAUTH_KEY=$(PANEL_OAUTH_KEY) \
@@ -120,7 +119,6 @@ deploy-production: publish-production ## Deploy new revision to GCP
120119
--region=$(region) \
121120
--port=8080 \
122121
--set-env-vars ENV=production \
123-
--set-env-vars PANEL_OAUTH_SCOPE=email \
124122
--set-secrets=PANEL_OAUTH_REDIRECT_URI=PANEL_OAUTH_REDIRECT_URI:latest \
125123
--set-secrets=PANEL_OAUTH_KEY=PANEL_OAUTH_KEY:latest \
126124
--set-secrets=PANEL_OAUTH_SECRET=PANEL_OAUTH_SECRET:latest \

panel/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ CMD ["panel", "serve", "panel/simdec_app.py", "panel/sampling.py", \
7272
"--basic-login-template", "panel/login.html", \
7373
"--logout-template", "panel/logout.html", \
7474
"--oauth-provider", "custom_google", \
75+
"--login-endpoint", "app", \
7576
"--index", "panel/index.html", \
7677
"--static-dirs", "_static=_static", \
7778
"--reuse-sessions", "--warm", \

panel/cloudbuild.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@ steps:
3232
- '--port=8080'
3333
- '--set-env-vars'
3434
- 'ENV=production'
35-
- '--set-env-vars'
36-
- 'PANEL_OAUTH_SCOPE=email'
3735
- '--set-secrets=PANEL_OAUTH_REDIRECT_URI=PANEL_OAUTH_REDIRECT_URI:latest'
3836
- '--set-secrets=PANEL_OAUTH_KEY=PANEL_OAUTH_KEY:latest'
3937
- '--set-secrets=PANEL_OAUTH_SECRET=PANEL_OAUTH_SECRET:latest'

0 commit comments

Comments
 (0)