k8s安装ingress-nginx
apiVersion: v1kind: Namespacemetadata:name: ingress-nginxlabels:app.kubernetes.io/name: ingress-nginxapp.kubernetes.io/part-of: ingress-nginx---kind: ConfigMapapiVersion: v1metadata:name: nginx-config
·
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
更多推荐
已为社区贡献2条内容
所有评论(0)