diff --git a/examples/auth/oauth-external-auth/index.html b/examples/auth/oauth-external-auth/index.html index b685493a1..66794f427 100644 --- a/examples/auth/oauth-external-auth/index.html +++ b/examples/auth/oauth-external-auth/index.html @@ -6,7 +6,7 @@ nginx.ingress.kubernetes.io/auth-signin: "https://$host/oauth2/start?rd=$escaped_request_uri" ...
This example will show you how to deploy oauth2_proxy
into a Kubernetes cluster and use it to protect the Kubernetes Dashboard using github as oAuth2 provider
kubectl create -f https://raw.githubusercontent.com/kubernetes/kops/master/addons/kubernetes-dashboard/v1.10.1.yaml
-
https://foo.bar.com
/oauth2
, like https://foo.bar.com/oauth2
Configure oauth2_proxy values in the file oauth2-proxy.yaml
with the values:
OAUTH2_PROXY_CLIENT_ID with the github <Client ID>
<Client Secret>
OAUTH2_PROXY_COOKIE_SECRET with value of python -c 'import os,base64; print(base64.b64encode(os.urandom(16)).decode("ascii"))'
Customize the contents of the file dashboard-ingress.yaml
:
Replace __INGRESS_HOST__
with a valid FQDN and __INGRESS_SECRET__
with a Secret with a valid SSL certificate.
$ kubectl create -f oauth2-proxy.yaml,dashboard-ingress.yaml
+
https://foo.bar.com
/oauth2/callback
, like https://foo.bar.com/oauth2/callback
Configure oauth2_proxy values in the file oauth2-proxy.yaml
with the values:
OAUTH2_PROXY_CLIENT_ID with the github <Client ID>
<Client Secret>
OAUTH2_PROXY_COOKIE_SECRET with value of python -c 'import os,base64; print(base64.b64encode(os.urandom(16)).decode("ascii"))'
Customize the contents of the file dashboard-ingress.yaml
:
Replace __INGRESS_HOST__
with a valid FQDN and __INGRESS_SECRET__
with a Secret with a valid SSL certificate.
$ kubectl create -f oauth2-proxy.yaml,dashboard-ingress.yaml
Test the oauth integration accessing the configured URL, like https://foo.bar.com