Browse Source

++nginx test deployment

master
Nico Schottelius 1 year ago
parent
commit
e67093bf8a
  1. 18
      v3-calico/README.md
  2. 19
      v3-calico/nginx-test-deployment.yaml

18
v3-calico/README.md

@ -66,3 +66,21 @@ alias calicoctl="kubectl exec -i -n kube-system calicoctl -- /calicoctl"
```
calicoctl create -f - < bgp....yaml
```
## Setup a test deployment
Do *NOT* use https://k8s.io/examples/application/deployment.yaml. It
contains an outdated nginx container that has no IPv6 listener. You
will get results such as
```
[19:03] server47.place7:~/ungleich-k8s/v3-calico# curl http://[2a0a:e5c0:13:bbb:176b:eaa6:6d47:1c41]
curl: (7) Failed to connect to 2a0a:e5c0:13:bbb:176b:eaa6:6d47:1c41 port 80: Connection refused
```
if you use that deployment. Instead use something on the line of the
included **nginx-test-deployment.yaml**:
```
kubectl appply -f nginx-test-deployment.yaml
```

19
v3-calico/nginx-test-deployment.yaml

@ -0,0 +1,19 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
spec:
selector:
matchLabels:
app: nginx
replicas: 2 # tells deployment to run 2 pods matching the template
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.20.0-alpine
ports:
- containerPort: 80
Loading…
Cancel
Save