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

theia-cloud: Make OAuth2 Proxy's allowed redirect domains configurable #89

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

xai
Copy link
Contributor

@xai xai commented Feb 12, 2025

  • Make whitelist_domains and cookie_domains configurable
  • Default is the previous behaviour: landing page and session host
  • Removes google.com from the default allowed redirects because there is no indication that this is necessary

Fixes eclipse-theia/theia-cloud#357

- Make whitelist_domains and cookie_domains configurable
- Default is the previous behaviour: landing page and session host
- Removes google.com from the default allowed redirects because there is
  no indication that this is necessary

Fixes eclipse-theia/theia-cloud#357

Signed-off-by: Olaf Lessenich <[email protected]>
Copy link
Contributor

@jfaltermeier jfaltermeier left a comment

Choose a reason for hiding this comment

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

LGTM. The only thing I noticed is an extra indent:

{
	"oauth2-proxy.cfg": "# Provider config
		provider=\"keycloak-oidc\"
		redirect_url=\"https://placeholder/oauth2/callback\"
		oidc_issuer_url=\"https://192.168.59.202.nip.io/keycloak/realms/TheiaCloud\"
		ssl_insecure_skip_verify=true
		# Client config
		client_id=\"theia-cloud\"
		client_secret=\"publicbutoauth2proxywantsasecret\"
		cookie_secret=\"s-p4GxfRlPa_BI1XsLuvE2ihNOqYD1vmewWcXcpYjr0=\"
		cookie_secure=\"false\"
		#proxy_prefix=\"\"
		# Upstream config
		http_address=\"0.0.0.0:5000\"
		upstreams=\"http://127.0.0.1:placeholder-port/\"
		# Proxy Config
		#user_id_claim=\"preferred_username\"
		skip_auth_routes=[\"/health.*\"]
		skip_provider_button=\"true\"
		reverse_proxy=\"true\"
		# email_domains=[\"*\"]
		    cookie_domains=[\"ws.192.168.59.202.nip.io\"]
		    whitelist_domains=[\"ws:*\",\"192.168.59.202.nip.io:*\"]
		custom_templates_dir=\"/templates\"
		"
}

It still worked as expected, but if it’s easy to fix, we might want to align it properly.

Also, please bump the chart version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

helm: Make OAuth2 Proxy's allowed redirect domains configurable
2 participants