Update README.md

This commit is contained in:
Dominik Chilla 2020-08-23 17:45:02 +02:00 committed by GitHub
parent 1caa068ac3
commit a856691295
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -108,15 +108,6 @@ spec:
protocol: TCP protocol: TCP
selector: selector:
run: my-nginx run: my-nginx
---
apiVersion: v1
kind: ConfigMap
metadata:
name: tcp-services
namespace: ingress-nginx
data:
9000: "default/my-nginx:80::PROXY"
``` ```
Apply with `kubectl apply -f my-nginx-deployment.yml`: Apply with `kubectl apply -f my-nginx-deployment.yml`:
``` ```
@ -158,6 +149,23 @@ spec:
<<< ADD *** <<< ADD ***
[...] [...]
``` ```
Finally, we need to glue nginx-ingress with the my-nginx app. This will be done with the config-map `tcp-services-config-map.yml` referenced earlier in the nginx-ingress deployment definition:
```
---
apiVersion: v1
kind: ConfigMap
metadata:
name: tcp-services
namespace: ingress-nginx
data:
9000: "default/my-nginx:80::PROXY"
```
Apply with `kubectl apply -f tcp-services-config-map.yml`:
```
configmap/tcp-services created
```
Verify nginx-ingress is listening on port 9000 with `kubectl get all --all-namespaces`: Verify nginx-ingress is listening on port 9000 with `kubectl get all --all-namespaces`:
``` ```
[...] [...]