nginx-ingress

How does Traffic Flow inside a Kubernetes Cluster?

血红的双手。 提交于 2019-12-10 10:29:36
问题 (While learning Kubernetes I never really found any good resources explaining this) Scenario: I own mywebsite1.com and mywebsite2.com and I want to host them both inside a Kubernetes Cluster. I deploy a generic cloud ingress controller according to the following website with 2 kubectl apply -f < url > commands. (mandatory.yaml and generic ingress.yaml) https://kubernetes.github.io/ingress-nginx/deploy/ So the question is what does that architecture look like? and how does the data flow into

How to use nginx ingress TCP service on different namespace [duplicate]

感情迁移 提交于 2019-12-08 13:02:28
问题 This question already has an answer here : TCP ingress support in Kubernetes (1 answer) Closed 4 months ago . I have deployed two namespace in the kubernetes cluster. The namespace A host mysql and namespace B run postgress and expose their service deployment on these ports Namespace(A) - mysql - port (3306) Namespace(B) - postgress - port (5432) I need to use nginx-ingress kubernetes cluster to route the traffic based, here is the sample YAML file for the ingress apiVersion: extensions

Setting cache-control headers for nginx ingress controller on kubernetes GKE

拟墨画扇 提交于 2019-12-06 11:45:15
问题 I have an ingress-nginx controller handling traffic to my Kubernetes cluster hosted on GKE. I set it up using helm installation instructions from docs: Docs here For the most part everything is working, but if I try to set cache related parameters via a server-snippet annotation, all of the served content that should get the cache-control headers comes back as a 404 . Here's my ingress-service.yaml file: apiVersion: extensions/v1beta1 kind: Ingress metadata: name: ingress-service annotations:

How does Traffic Flow inside a Kubernetes Cluster?

末鹿安然 提交于 2019-12-06 05:40:27
(While learning Kubernetes I never really found any good resources explaining this) Scenario: I own mywebsite1.com and mywebsite2.com and I want to host them both inside a Kubernetes Cluster. I deploy a generic cloud ingress controller according to the following website with 2 kubectl apply -f < url > commands. (mandatory.yaml and generic ingress.yaml) https://kubernetes.github.io/ingress-nginx/deploy/ So the question is what does that architecture look like? and how does the data flow into the Cluster? I convert 2 certificates to 2 .key and 2 .crt files I use those files to make 2 TLS secrets

Setting cache-control headers for nginx ingress controller on kubernetes GKE

纵然是瞬间 提交于 2019-12-04 17:57:59
I have an ingress-nginx controller handling traffic to my Kubernetes cluster hosted on GKE. I set it up using helm installation instructions from docs: Docs here For the most part everything is working, but if I try to set cache related parameters via a server-snippet annotation, all of the served content that should get the cache-control headers comes back as a 404 . Here's my ingress-service.yaml file: apiVersion: extensions/v1beta1 kind: Ingress metadata: name: ingress-service annotations: kubernetes.io/ingress.class: nginx nginx.ingress.kubernetes.io/proxy-read-timeout: "4000" nginx

Configure Ingress controller to forward custom http headers

霸气de小男生 提交于 2019-12-04 10:25:55
We are setting up an AKS cluster on Azure, following this guide We are running 5 .Net Core API's behind an ingress controller, everything works fine, requests are being routed nicely. However, in our SPA Frontend, we are sending a custom http header to our API's, this header never seems to make it to the API's, when we inspect the logging in AKS we see the desired http header is empty. In development, everything works fine, we also see the http header is filled in our test environment in AKS, so i'm guessing ingress is blocking these custom headers. Is there any configuration required to make

nginx-ingress config map snippets being ignored by the nginx.conf

邮差的信 提交于 2019-12-03 17:17:27
问题 I have a kubernetes cluster, where I have deployed an nginx ingress controller using the helm nginx-ingress chart. I need to add some custom config to the nginx.conf file that is generated in the nginx-controller-pod, and I am seeing an issue where if I add a one line option such as proxy-buffer-size: "512k" I can see this reflected in the nginx.conf file and everything works as expected. However, if I attempt to add a snippet to accomplish the same thing: location-snippet: | proxy_buffer

nginx-ingress config map snippets being ignored by the nginx.conf

爷,独闯天下 提交于 2019-12-03 06:17:38
I have a kubernetes cluster, where I have deployed an nginx ingress controller using the helm nginx-ingress chart . I need to add some custom config to the nginx.conf file that is generated in the nginx-controller-pod, and I am seeing an issue where if I add a one line option such as proxy-buffer-size: "512k" I can see this reflected in the nginx.conf file and everything works as expected. However, if I attempt to add a snippet to accomplish the same thing: location-snippet: | proxy_buffer_size "512k"; It is as though this is ignored by the nginx.conf file and the proxy_buffer_size setting

Kubernetes ingress-nginx gives 502 error (Bad Gateway)

坚强是说给别人听的谎言 提交于 2019-12-02 07:01:44
问题 I have an EKS cluster for which I want : - 1 Load Balancer per cluster, - Ingress rules to direct to the right namespace and the right service. I have been following this guide : https://www.digitalocean.com/community/tutorials/how-to-set-up-an-nginx-ingress-with-cert-manager-on-digitalocean-kubernetes My deployments: apiVersion: apps/v1 kind: Deployment metadata: name: hello-world namespace: default spec: replicas: 3 selector: matchLabels: app: hello-world template: metadata: labels: app:

Ingress and Ingress controller how to use them with NodePort Services?

。_饼干妹妹 提交于 2019-12-02 02:46:58
问题 I have a single service running on a NodePort service. How do i use ingress to access multiple services. deployment.yml apiVersion: apps/v1 kind: Deployment metadata: name: auth spec: replicas: 1 selector: matchLabels: app: auth template: metadata: labels: app: auth tier: backend track: dev spec: containers: - name: auth image: [url]/auth_app:v2 ports: - name: auth containerPort: 3000 service.yml apiVersion: v1 kind: Service metadata: name: auth spec: selector: app: auth tier: backend ports: