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

the ingress controller config failed when use regex path #3272

Closed
hchenxa opened this issue Oct 19, 2018 · 3 comments
Closed

the ingress controller config failed when use regex path #3272

hchenxa opened this issue Oct 19, 2018 · 3 comments

Comments

@hchenxa
Copy link
Contributor

hchenxa commented Oct 19, 2018

Is this a request for help? (If yes, you should use our troubleshooting guide and community support channels, see https://kubernetes.io/docs/tasks/debug-application-cluster/troubleshooting/.):

What keywords did you search in NGINX Ingress controller issues before filing this one? (If you have found any duplicates, you should instead reply there.):


Is this a BUG REPORT or FEATURE REQUEST? (choose one):

NGINX Ingress controller version:
0.19.0

Kubernetes version (use kubectl version):
v1.11.1

Environment:

  • Cloud provider or hardware configuration:
  • OS (e.g. from /etc/os-release):
  • Kernel (e.g. uname -a):
  • Install tools:
  • Others:

What happened:

refer the to config the local regx, https://kubernetes.github.io/ingress-nginx/user-guide/ingress-path-matching/#example_1

the nginx ingress controller config failed like below:

I1019 03:52:18.079192       8 controller.go:171] Configuration changes detected, backend reload required.
I1019 03:52:18.080406       8 util.go:68] rlimit.max=1048576
I1019 03:52:18.080422       8 nginx.go:525] Maximum number of open file descriptors: 64512
E1019 03:52:18.121635       8 controller.go:183] Unexpected failure reloading the backend:

-------------------------------------------------------------------------------
Error: exit status 1
2018/10/19 03:52:18 [emerg] 9278#9278: unknown directive "3}" in /tmp/nginx-cfg761235695:645
nginx: [emerg] unknown directive "3}" in /tmp/nginx-cfg761235695:645
nginx: configuration file /tmp/nginx-cfg761235695 test failed

-------------------------------------------------------------------------------
W1019 03:52:18.121659       8 queue.go:130] requeuing default/test-ingress-3, err
-------------------------------------------------------------------------------
Error: exit status 1
2018/10/19 03:52:18 [emerg] 9278#9278: unknown directive "3}" in /tmp/nginx-cfg761235695:645
nginx: [emerg] unknown directive "3}" in /tmp/nginx-cfg761235695:645
nginx: configuration file /tmp/nginx-cfg761235695 test failed

-------------------------------------------------------------------------------

What you expected to happen:

How to reproduce it (as minimally and precisely as possible):

Anything else we need to know:

@hchenxa
Copy link
Contributor Author

hchenxa commented Oct 19, 2018

check the nginx.conf, the location like below:

	location /foo/bar/[A-Z0-9]{3} {

		set $namespace      "default";
		set $ingress_name   "test-ingress-3";
		set $service_name   "test";
		set $service_port   "80";

I am not sure if we should add double quotation marks like below:

	location "/foo/bar/[A-Z0-9]{3}" {

		set $namespace      "default";
		set $ingress_name   "test-ingress-3";
		set $service_name   "test";
		set $service_port   "80";

cc @aledbf comments?

@aledbf
Copy link
Member

aledbf commented Oct 19, 2018

Closing. This is fixed in 0.20.0 #3182

@aledbf aledbf closed this as completed Oct 19, 2018
@hchenxa
Copy link
Contributor Author

hchenxa commented Oct 19, 2018

great, I will try with 0.20.0.

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

No branches or pull requests

2 participants