Skip to content
This repository has been archived by the owner on Jan 24, 2019. It is now read-only.

proxy_prefix doesn't work? #609

Open
veselov opened this issue Jun 1, 2018 · 1 comment
Open

proxy_prefix doesn't work? #609

veselov opened this issue Jun 1, 2018 · 1 comment

Comments

@veselov
Copy link

veselov commented Jun 1, 2018

Hello.

I'm trying to set up oauth2_proxy with nginx. I've specified:

proxy_prefix = "/gitlab-oauth"

In the config file. However, it doesn't seem to take for ".../auth" URL:

It seems I'm stuck with using "/oauth2" root prefix?

[root@ip-10-44-6-158 oauth-proxy]# telnet localhost 4180
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
GET /gitlab-oauth/auth HTTP/1.0

HTTP/1.0 403 Forbidden
Set-Cookie: xl4-gitlab-oau-dev=; Path=/; Expires=Fri, 01 Jun 2018 03:39:22 GMT; HttpOnly
Date: Fri, 01 Jun 2018 04:39:22 GMT
Content-Type: text/html; charset=utf-8
<...snip...>
Connection closed by foreign host.
[root@ip-10-44-6-158 oauth-proxy]# telnet localhost 4180
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
GET /oauth2/auth HTTP/1.0

HTTP/1.0 401 Unauthorized
Content-Type: text/plain; charset=utf-8
X-Content-Type-Options: nosniff
Date: Fri, 01 Jun 2018 04:39:32 GMT
Content-Length: 21

unauthorized request
Connection closed by foreign host.

Thank you for the awesome project :)

@ploxiln
Copy link
Contributor

ploxiln commented Jun 1, 2018

it's proxy-prefix in the config (dash, not underscore) (admittedly not matching the general convention of "dash in cmdline flag, underscore in config file")

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

No branches or pull requests

2 participants