Reputation: 40510
Due to limitations of ingress resources (in my case I need more than 50 routes which is not supported in Google Container Engine) I'm considering using Nginx as a reverse proxy to other backend services. What I want to do is essentially the same as an ingress resource provides such as routing path "/x" to service x and "/y" to service y. I'd like to run more than one instance of Nginx for HA, probably behind a service. My question mainly concerns configuration where I have a couple of options:
Upvotes: 1
Views: 2551
Reputation: 1316
ConfigMaps containing text-files should be no problem at all. Take a look at the --from-file
option: http://kubernetes.io/docs/user-guide/configmap/.
Im unsure about binary files inside a ConfigMap. I'm able to add a JPEG but trying to read object results in an error so this might not be intended (needs additional base64 encoding or such).
$ kubectl create configmap test --from-file=foo1=/tmp/scudcloud_U0GQ27N0M.jpg
configmap "test" created
$ kubectl get configmap test -o yaml
error: error converting JSON to YAML: %!(EXTRA *errors.errorString=yaml: control characters are not allowed)
Upvotes: 3