GKE 是否支持使用静态 ip 的 nginx-ingress? [英] Does GKE support nginx-ingress with static ip?

查看:28
本文介绍了GKE 是否支持使用静态 ip 的 nginx-ingress?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在使用 Google Cloud Load Balancer 入口.但是,我正在尝试在 GKE 中具有静态 IP 地址的节点中安装 nginxinc/kubernetes-ingress 控制器.

I have been using the Google Cloud Load Balancer ingress. However, I'm trying to install a nginxinc/kubernetes-ingress controller in a node with a Static IP address in GKE.

  1. 我可以在同一个集群中使用 Google 的 Cloud Load Balancer 入口控制器吗?
  2. 我们如何使用带有静态 IP 的 nginxinc/kubernetes-ingress?

谢谢

推荐答案

如果您使用 helm 部署 nginx-ingress.

In case you're using helm to deploy nginx-ingress.

首先创建一个静态 IP 地址.在 google 中,网络负载均衡器 (NLB) 仅支持区域静态 IP:

First create a static IP address. In google the Network Loadbalancers (NLBs) only support regional static IPs:

gcloud compute addresses create my-static-ip-address --region us-east4

然后用ip地址作为loadBalancerIP参数安装nginx-helm

Then install nginx-helm with the ip address as a loadBalancerIP parameter

helm install --name nginx-ingress stable/nginx-ingress --namespace my-namespace --set controller.service.loadBalancerIP=35.186.172.1

这篇关于GKE 是否支持使用静态 ip 的 nginx-ingress?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆