在这里插入图片描述
在这里插入图片描述

kubectl apply -f mandatory.yaml
kubectl get po -n ingress-nginx -o wide
kubectl describe pod nginx-ingress-controller-564746777d-thj47 -n ingress-nginx

在这里插入图片描述
在这里插入图片描述

apiVersion: v1
kind: Service
metadata:
  name: ingress-nginx
  namespace: ingress-nginx
  labels:
    app.kubernetes.io/name: ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
spec:
  type: NodePort
  ports:
    - name: http
      port: 80
      targetPort: 80
      protocol: TCP
      nodePort: 32080
    - name: https
      port: 443
      targetPort: 443
      protocol: TCP
      nodePort: 32443
  selector:
    app.kubernetes.io/name: ingress-nginx
    app.kubernetes.io/part-of: ingress-ngin
kubectl apply -f service-nodeport.yaml
kubectl get po -n ingress-nginx -o wide
kubectl get svc -n ingress-nginx -o wide
kubectl describe svc ingress-nginx -n ingress-nginx
kubectl -n ingress-nginx get all
kubectl apply -f mandatory.yaml --enable-ssl-chain-completion=false

在这里插入图片描述

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐