“Kubernetes ingress基础”的版本间的差异

来自linux中国网wiki
跳转至: 导航搜索
(创建页面,内容为“ =see also= [https://blog.csdn.net/newcrane/article/details/79092577 kubernetes中服务的暴露访问方式kubernetes ingress使用] category:k8s”)
 
see also
(未显示同一用户的1个中间版本)
第1行: 第1行:
 +
 +
Nginx ingress 使用ConfigMap来管理Nginx配置,nginx是大家熟知的代理和负载均衡软件,比起Traefik来说功能更加强大.
 +
==install==
 +
<pre>
 +
 +
#FQ吧 少年
 +
wget -c  https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/mandatory.yaml
 +
 +
kubectl apply -f mandatory.yaml
 +
 +
namespace/ingress-nginx configured
 +
configmap/nginx-configuration unchanged
 +
configmap/tcp-services created
 +
configmap/udp-services created
 +
serviceaccount/nginx-ingress-serviceaccount unchanged
 +
clusterrole.rbac.authorization.k8s.io/nginx-ingress-clusterrole configured
 +
role.rbac.authorization.k8s.io/nginx-ingress-role unchanged
 +
rolebinding.rbac.authorization.k8s.io/nginx-ingress-role-nisa-binding unchanged
 +
clusterrolebinding.rbac.authorization.k8s.io/nginx-ingress-clusterrole-nisa-binding unchanged
 +
deployment.apps/nginx-ingress-controller configured
 +
 +
 +
Verify installation
 +
To check if the ingress controller pods have started,
 +
 +
kubectl get pods --all-namespaces -l app.kubernetes.io/name=ingress-nginx --watch
 +
NAMESPACE      NAME                                        READY  STATUS            RESTARTS  AGE
 +
ingress-nginx  nginx-ingress-controller-86449c74bb-rthhw  0/1    ImagePullBackOff  0          2m5s
 +
 +
kubectl get pods -n ingress-nginx -o wide --watch #也是查看
 +
 +
 +
Once the operator pods are running, you can cancel the above command by typing Ctrl+C.
 +
 +
可见上面还不是runing  过一阵才好
 +
 +
kubectl get pods -n ingress-nginx
 +
NAME                                        READY  STATUS    RESTARTS  AGE
 +
nginx-ingress-controller-86449c74bb-rthhw  1/1    Running  0          19h
 +
 +
</pre>
 +
 +
=trouble=
 +
<pre> kubectl get ing #ADDRESS 为空
 +
NAME    HOSTS  ADDRESS  PORTS  AGE
 +
simple  *                80      4s
 +
</pre>
 +
  
 
=see also=
 
=see also=
 +
[https://kubernetes.github.io/ingress-nginx/deploy/ 官方文档]
 +
 +
[https://blog.csdn.net/java_zyq/article/details/82179107 从零开始搭建K8S--搭建K8S Ingress]
 +
 +
 +
[https://help.aliyun.com/document_detail/86533.html?spm=5176.2020520165.119.d86533.2d357029XalTRt aliyun Ingress 支持]
 +
 +
[https://blog.csdn.net/java_zyq/article/details/82496842 k8s安装traefik作为ingress]
 +
 +
 +
[https://my.oschina.net/u/2306127/blog/1793287 通过helm Nginx ingress安装]
 +
 +
 +
[https://blog.csdn.net/liyingke112/article/details/77069593 为什么我不使用Kubernetes的Ingress]
 +
 +
 
[https://blog.csdn.net/newcrane/article/details/79092577  kubernetes中服务的暴露访问方式kubernetes ingress使用]
 
[https://blog.csdn.net/newcrane/article/details/79092577  kubernetes中服务的暴露访问方式kubernetes ingress使用]
 +
 +
 +
[https://blog.csdn.net/java_zyq/article/details/82179107 搭建K8S Ingress安装部分已老]
 
[[category:k8s]]
 
[[category:k8s]]

2019年7月12日 (五) 14:12的版本

Nginx ingress 使用ConfigMap来管理Nginx配置,nginx是大家熟知的代理和负载均衡软件,比起Traefik来说功能更加强大.

install


#FQ吧 少年 
wget -c  https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/mandatory.yaml

kubectl apply -f mandatory.yaml 

namespace/ingress-nginx configured
configmap/nginx-configuration unchanged
configmap/tcp-services created
configmap/udp-services created
serviceaccount/nginx-ingress-serviceaccount unchanged
clusterrole.rbac.authorization.k8s.io/nginx-ingress-clusterrole configured
role.rbac.authorization.k8s.io/nginx-ingress-role unchanged
rolebinding.rbac.authorization.k8s.io/nginx-ingress-role-nisa-binding unchanged
clusterrolebinding.rbac.authorization.k8s.io/nginx-ingress-clusterrole-nisa-binding unchanged
deployment.apps/nginx-ingress-controller configured


Verify installation
To check if the ingress controller pods have started,

 kubectl get pods --all-namespaces -l app.kubernetes.io/name=ingress-nginx --watch
NAMESPACE       NAME                                        READY   STATUS             RESTARTS   AGE
ingress-nginx   nginx-ingress-controller-86449c74bb-rthhw   0/1     ImagePullBackOff   0          2m5s

kubectl get pods -n ingress-nginx -o wide --watch #也是查看 


Once the operator pods are running, you can cancel the above command by typing Ctrl+C. 

可见上面还不是runing  过一阵才好

 kubectl get pods -n ingress-nginx 
NAME                                        READY   STATUS    RESTARTS   AGE
nginx-ingress-controller-86449c74bb-rthhw   1/1     Running   0          19h

trouble

 kubectl get ing #ADDRESS 为空
NAME     HOSTS   ADDRESS   PORTS   AGE
simple   *                 80      4s


see also

官方文档

从零开始搭建K8S--搭建K8S Ingress


aliyun Ingress 支持

k8s安装traefik作为ingress


通过helm Nginx ingress安装


为什么我不使用Kubernetes的Ingress


kubernetes中服务的暴露访问方式kubernetes ingress使用


搭建K8S Ingress安装部分已老