嗨,我在社区和 Nginx 存储库中都使用了 Nginx 控制器,它们都适用于云LoadBalancer
服务。作为 Nginx 控制器,社区和 Nginx 存储库都不能使用服务Nodeport
“错误 404”。
404 Not Found
服务类型节点端口
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
- name: https
port: 443
targetPort: 443
protocol: TCP
selector:
app.kubernetes.io/name: ingress-nginx
app.kubernetes.io/part-of: ingress-nginx