zoukankan      html  css  js  c++  java
  • Traefikingress

    [root@k8s-master-01 traefik]# git clone https://github.com/containous/traefik.git
    (一般只需要两个文件:deployment和rbac。)
    (由于在Kubernets1.6之后启用了RBAC鉴权机制,所以需配置ClusterRole以及ClusterRoleBinding来对api-server的进行相应权限的鉴权。)
    (rbac这个文件呢就是创建ClusterRole和ClusterRoleBinding的。)
    [root@k8s-master-01 TrIngress]# kubectl apply -f traefik-rbac.yaml clusterrole.rbac.authorization.k8s.io/traefik-ingress-controller created clusterrolebinding.rbac.authorization.k8s.io/traefik-ingress-controller created [root@k8s-master-01 TrIngress]# kubectl get clusterrolebinding NAME AGE traefik-ingress-controller 29s [root@k8s-master-01 TrIngress]# kubectl get clusterrole NAME AGE traefik-ingress-controller 67s
    [root@k8s-master-01 TrIngress]# kubectl apply -f traefik-deployment.yaml
    serviceaccount/traefik-ingress-controller created
    deployment.extensions/traefik-ingress-controller created
    service/traefik-ingress-service created
    [root@k8s-master-01 ~]# kubectl get pod --all-namespaces -owide
    NAMESPACE     NAME                                    READY   STATUS    RESTARTS   AGE   IP            NODE            NOMINATED NODE
    kube-system   traefik-ingress-controller-5ddql        1/1     Running   6          39h   10.10.0.135   k8s-node-02     <none>
    kube-system   traefik-ingress-controller-x6xrx        1/1     Running   0          39h   10.10.0.190   k8s-node-01     <none>

    (参考链接:http://blog.51cto.com/goome/2151353。)

    到这就算完成了,下一步我们看看该怎样使用它。

  • 相关阅读:
    [asp.net core]SignalR一个例子
    [Asp.net core]bootstrap分页
    ${pageContext.request.contextPath}无法解析
    [Java web]Spring+Struts2+Hibernate整合过程(2)
    [Java web]Spring+Struts2+Hibernate整合过程
    java.lang.IllegalStateException: Failed to load ApplicationContext
    [Struts2]配置文件
    unihtmlmemo使用
    ADO序列
    variant和rawbytestring相互转换
  • 原文地址:https://www.cnblogs.com/fengzhihai/p/10016216.html
Copyright © 2011-2022 走看看