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

Failed to mkdir SSL directory: mkdir /ingress-controller: permission denied #205

Closed
git001 opened this issue Aug 14, 2018 · 0 comments · Fixed by #206
Closed

Failed to mkdir SSL directory: mkdir /ingress-controller: permission denied #205

git001 opened this issue Aug 14, 2018 · 0 comments · Fixed by #206

Comments

@git001
Copy link
Contributor

git001 commented Aug 14, 2018

I wanted to run the ingress controller in OpenShift/okd.
There are currently 2 issues for this.

  1. you will need to add the serviceaccount by default into the deployment as OpenShift runs by default rbac
  2. As in OpenShift is can't the directory /ingress-controller be created

I haven't seen the docker file for the Image so I can't create a PR for this.
How about to create the directory /ingress-controller in the image and set the proper permission to it?

Here is the output from the pod

oc -n ingress-controller logs haproxy-ingress-b5c5dc5c9-7v5xt
Reload strategy: native
I0814 19:46:32.271890       5 launch.go:141]
Name:       HAProxy
Release:    v0.5
Build:      git-2d4dceb
Repository: https://github.com/jcmoraisjr/haproxy-ingress
I0814 19:46:32.271994       5 launch.go:144] Watching for ingress class: haproxy
I0814 19:46:32.272494       5 launch.go:340] Creating API client for https://172.30.0.1:443
I0814 19:46:32.294166       5 launch.go:352] Running in Kubernetes Cluster version v1.10+ (v1.10.0+b81c8f8) - git (clean) commit b81c8f8 - platform linux/amd64
I0814 19:46:32.296205       5 launch.go:168] validated ingress-controller/ingress-default-backend as the default backend
E0814 19:46:32.296263       5 launch.go:219] Failed to mkdir SSL directory: mkdir /ingress-controller: permission denied
I0814 19:46:32.300996       5 controller.go:1263] starting Ingress controller
I0814 19:46:32.314967       5 event.go:218] Event(v1.ObjectReference{Kind:"Ingress", Namespace:"ingress-controller", Name:"app", UID:"80263b13-9ff7-11e8-8ed9-366edd0cf5fb", APIVersion:"extensions", ResourceVersion:"6834", FieldPath:""}): type: 'Normal' reason: 'CREATE' Ingress ingress-controller/app
F0814 19:46:33.016858       5 controller.go:1315] Error generating self signed certificate: could not create temp pem file /ingress-controller/ssl/default-fake-certificate.pem: open /ingress-controller/ssl/default-fake-certificate.pem231015794: no such file or directory

The output with v0.6-beta.3

[root@master001 ~]# oc logs haproxy-ingress-7bfb9cd5b9-ggfkk
I0814 19:57:32.173064       5 launch.go:141]
Name:       HAProxy
Release:    v0.6-beta.3
Build:      git-0218c78
Repository: https://github.com/jcmoraisjr/haproxy-ingress
I0814 19:57:32.173169       5 launch.go:144] Watching for ingress class: haproxy
I0814 19:57:32.173433       5 launch.go:344] Creating API client for https://172.30.0.1:443
I0814 19:57:32.182731       5 launch.go:356] Running in Kubernetes Cluster version v1.10+ (v1.10.0+b81c8f8) - git (clean) commit b81c8f8 - platform linux/amd64
I0814 19:57:32.185577       5 launch.go:168] validated ingress-controller/ingress-default-backend as the default backend
F0814 19:57:32.185636       5 launch.go:219] Failed to mkdir SSL directory: mkdir /ingress-controller: permission denied
git001 added a commit to git001/haproxy-ingress that referenced this issue Aug 14, 2018
Add the directory `/ingress-controller` because in OpenShift can't the pod create the root dir
fix jcmoraisjr#205
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 a pull request may close this issue.

1 participant