Created
December 3, 2022 19:01
-
-
Save erangaeb/1483a19c9b8e6cd460ff389e197fbd49 to your computer and use it in GitHub Desktop.
run nginx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# run nginx | |
kubectl apply -f nginx1.yaml | |
kubectl apply -f nginx2.yaml | |
❯❯ kubectl get pods | grep nginx | |
nginx1 1/1 Running 0 64m | |
nginx2 1/1 Running 0 62m | |
❯❯ kubectl get svc | grep nginx | |
nginx1 LoadBalancer 10.110.184.190 <pending> 80:32198/TCP 65m | |
nginx2 LoadBalancer 10.96.206.103 <pending> 80:30533/TCP 63m | |
# nginx service has the label `app.kubernetes.io/component=blackbox` | |
❯❯ kubectl describe svc nginx1 | |
Name: nginx1 | |
Namespace: default | |
Labels: app.kubernetes.io/component=blackbox | |
name=nginx1 | |
Annotations: <none> | |
Selector: app=nginx1 | |
Type: LoadBalancer | |
IP Family Policy: SingleStack | |
IP Families: IPv4 | |
IP: 10.110.184.190 | |
IPs: 10.110.184.190 | |
Port: <unset> 80/TCP | |
TargetPort: 80/TCP | |
NodePort: <unset> 32198/TCP | |
Endpoints: 172.17.0.7:80 | |
Session Affinity: None | |
External Traffic Policy: Cluster | |
Events: <none> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment