-
Notifications
You must be signed in to change notification settings - Fork 1
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
SS 693 ingress does not care if app is public or private #101
SS 693 ingress does not care if app is public or private #101
Conversation
…settings removes auth-url
try: | ||
print("Ingress v1beta1: {}".format(settings.INGRESS_V1BETA1)) | ||
parameters["ingress"]["v1beta1"] = settings.INGRESS_V1BETA1 | ||
except: # noqa E722 TODO: Add exception | ||
pass |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fails always, so i've removed it.
@@ -203,19 +203,14 @@ def deploy_resource(instance_pk, action="create"): | |||
app_instance = AppInstance.objects.select_for_update().get(pk=instance_pk) | |||
status = AppStatus(appinstance=app_instance) | |||
|
|||
if action == "create": | |||
if (action == "create") or (action == "update"): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding update action that actually updates the app parameters. This was not done before some some odd reason.
{{ if ne .Values.permission "public" }} | ||
nginx.ingress.kubernetes.io/auth-url: "{{ .Values.global.protocol }}://{{ .Values.global.auth_domain }}:8080/auth/?release={{ .Values.release }}" | ||
nginx.ingress.kubernetes.io/auth-signin: "https://{{ .Values.global.domain }}/accounts/login/?next=$scheme%3A%2F%2F$host" | ||
#nginx.ingress.kubernetes.io/auth-response-headers: X-Forwarded-Host | ||
{{- end }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is added to ingress files for dash, shiny, custom app etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like I'm not the one to approve, but I did something similar for making mlflow public. So I feel like it's okay.
I hope you've tried accessing apps via incognito with this
Yes i've tried that, using multiple browsers and even curl |
Description
Bug description:
Creating a public app means that Django makes it public in the UI, but accessing the app without being logged in is blocked by ingress.
Fix
There are probably a better permanent solution, but me and Hamza thought that this will do for now.
This is how the fix works.
{"permission": "public"}
yaml
file has anif
statement, so if permission is public, then we do not require login.In order to fix this, i have
if
statement to all apps that can be made public (Shiny, dash, custom app etc)In addition to this, i have removed a bunch of unnecessary
v1beta
statements in ingress. These are never used.Checklist
If you're unsure about any of the items below, don't hesitate to ask. We're here to help!
This is simply a reminder of what we are going to look for before merging your code.