nginx-ingress-controller
manifests 方式部署
拉取代码至本地
git clone https://github.com/nginx/kubernetes-ingress.git --branch v4.0.1
cd kubernetes-ingress创建所需配置文件
kubectl apply -f deployments/common/ns-and-sa.yaml
kubectl apply -f deployments/rbac/rbac.yaml
kubectl apply -f deployments/common/nginx-config.yaml
kubectl apply -f deployments/common/ingress-class.yaml
# 不指定 ingressClassName 的 ingress 都默认使用它,需进行如下修改
# If you want to make this NGINX Ingress Controller instance your cluster’s default,
# uncomment the "ingressclass.kubernetes.io/is-default-class" annotation.
# This action will auto-assign IngressClass to new ingresses that don’t specify an ingressClassName.创建自定义资源并以 Deployment 方式创建 NGINX Ingress Controller
查看状态
访问 NGINX Ingress Controller
Last updated