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

nginx-alpha Ingress Controller ProxyPass syntax issue #1266

Closed
aLostEngineer opened this issue Jun 24, 2016 · 6 comments
Closed

nginx-alpha Ingress Controller ProxyPass syntax issue #1266

aLostEngineer opened this issue Jun 24, 2016 · 6 comments

Comments

@aLostEngineer
Copy link

The ProxyPass URL must have a trailing forward-slash to properly proxy to the root of another http service. Furthermore, the Ingress points must be declared with trailing slashes to match.

Example: with the current setup, if I have a ingress /a pointing to a backend nginx service, the Ingress service will keep the /a subdirectory appended, forcing the backend service to try to access <service>/a, instead of the webroot.

Adding a trailing forward slash to the Ingress point and nginx config will properly forward HTTP requests.

@aLostEngineer aLostEngineer changed the title nginx-alpha Ingress Controller ProxyPass syntax incorrect nginx-alpha Ingress Controller ProxyPass syntax issue Jun 24, 2016
@aledbf
Copy link
Contributor

aledbf commented Jun 24, 2016

@aLostEngineer the behavior you are describing is correct.
What you are proposing is a rewrite (which can break some apps). Please check this issues #679 and #860

@aLostEngineer
Copy link
Author

@aledbf is the ingress rewrite directive ready for deployment? If so, I can close the issues/PRs. From what it looks like here, it is. If so, maybe I should add an example to the nginx-alpha README instead?

@aLostEngineer
Copy link
Author

Closed PR #1267 and Issue #1268 until I am better informed on newer features.

@aledbf
Copy link
Contributor

aledbf commented Jun 24, 2016

is the ingress rewrite directive ready for deployment?

Yes.

@aLostEngineer nginx-alpha and nginx are different implementations of an Ingress controllers.
I'm not sure about the change in the readme.

ping @bprashanth

@aLostEngineer
Copy link
Author

@aledbf Ok, thanks. I'll refactor our deploy to use the rewrite option in Ingress.

Closing.

@bprashanth
Copy link

Yeah this is one area that we compromise usability on one backend for cross platform compat. Annotations/config map is the way to expose such features. Please do add examples (but to the main nginx controller, since nginx-alpha is a toy example that is intentionally kept as simple as possible).

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

No branches or pull requests

3 participants