今天就跟大家聊聊有關(guān)Tungsten Fabric及Kubernetes集成解決是怎樣的,可能很多人都不太了解,為了讓大家更加了解,小編給大家總結(jié)了以下內(nèi)容,希望大家根據(jù)這篇文章可以有所收獲。
讓客戶滿意是我們工作的目標,不斷超越客戶的期望值來自于我們對這個行業(yè)的熱愛。我們立志把好的技術(shù)通過有效、簡單的方式提供給客戶,將通過不懈努力成為客戶在信息化領(lǐng)域值得信任、有價值的長期合作伙伴,公司提供的服務(wù)項目有:域名申請、網(wǎng)頁空間、營銷軟件、網(wǎng)站建設(shè)、蛟河網(wǎng)站維護、網(wǎng)站推廣。
1
Kubernetes與TF的集成
contrail-kube-manager和kube-api-server
Contrail CNI
1.2 Contrail CNI
[KUBERNETES_VNC]public_fip_pool = {'domain': 'default-domain', 'project': 'default', 'network': 'public', 'name': 'public-fip-pool'}
[VNC]public_fip_pool = {'domain': 'default-domain', 'project': 'default', 'network': 'public', 'name': 'public-fip-pool'}
2
Namespace
[KUBERNETES]cluster_project = {'domain': 'default-domain', 'project': 'kubernetes'}
Flat IPAM <cluster_project>:具有子網(wǎng)的pod-ipam
IPAM <cluster_project>:service-ipam
虛擬網(wǎng)絡(luò)“cluster-network”的安全組k8s-default-default-default和k8s-default-default-sg
虛擬網(wǎng)絡(luò)<cluster_project>:具有pod-ipam和service-ipam的cluster-network
apiVersion: v1kind: Namespacemetadata: name: "dev-unisolated"
apiVersion: v1kind: Podmetadata: name: nginx-1spec: containers: - name: nginx image: docker.io/nginx imagePullPolicy: IfNotPresentkubectl create -f nginx-1.yaml -n <namespace>kubectl get pods -n <namespace>
創(chuàng)建虛擬機<NS name>-<pod name>__<VM UUID>。
在啟動Pod的虛擬路由器中,添加對VM的引用。
參考以下內(nèi)容,創(chuàng)建VMI <cluster_project>:<pod name>__<VMI UUID>。
SG k8s-default-<NS name>-default
SG k8s-default-<NS name>-sg
VN <cluster_project>:cluster-network
在VN cluster-network中從pod-ipam分配IP地址(cluster IP)。Subnet UUID被指定為從Flat IPAM pod-ipam進行分配。
apiVersion: v1kind: Namespacemetadata: name: "dev-isolated" annotations: { "opencontrail.org/isolation" : "true" }
虛擬網(wǎng)絡(luò)<cluster_project>:<namespace name>-vn
安全組k8s-default-<namespace name>-default和k8s-default-<namespace name>-sg
創(chuàng)建虛擬機<NS name>-<pod name>__<VM UUID>。
在啟動了Pod的虛擬路由器中,添加對VM的引用。
參考以下內(nèi)容,創(chuàng)建VMI <cluster_project>:<pod name>__<VMI UUID>。
SG k8s-default-<NS name>-default
SG k8s-default-<NS name>-sg
VN <cluster_project>:<NS name>-vn
在VN <NS name>-vn中從pod-ipam分配IP地址(cluster IP)。Subnet UUID被指定為從flat IPAM pod-ipam進行分配。
為每個現(xiàn)有的Kubenetes命名空間(如default、kube-public和kube-system)提供一個項目/租戶。
Flat IPAM 默認域:default:pod-ipam
IPAM 默認域:default:service-ipam
每一個命名空間的安全組:k8s-default-<namespace>-sg和k8s-default-<namespace>-sg
虛擬網(wǎng)絡(luò)默認域名:具有pod-ipam的default:cluster-network和service-ipam
apiVersion: v1kind: Namespacemetadata: name: "dev-unisolated"
項目default-domain:<namespace>
在項目缺省域:<namespace>
在虛擬網(wǎng)絡(luò)缺省域:default:cluster-network
從IPAM缺省域:default:pod-ipam獲取地址
附帶安全組k8s-default-default-default和k8s-default-default-sg
apiVersion: v1kind: Namespacemetadata: name: "dev-isolated" annotations: { "opencontrail.org/isolation" : "true" }
項目缺省域:<namespace>
虛擬網(wǎng)絡(luò)default-domain:<namespace>:<namespace>-vn與default-domain:default:pod-ipam關(guān)聯(lián)。
安全組default-domain:<namespace>:k8s-default-<namespace>-default和default-domain:<namespace>:k8s-default-<namespace>-sg
在項目default-domain:<namespace>中
在虛擬網(wǎng)絡(luò)default-domain:<namespace>:<namespace>-vn上
從IPAM default-domain:default:pod-ipam獲取地址
附帶安全組default-domain:<namespace>:k8s-default-<namespace>-default和default-domain:<namespace>:k8s-default-<namespace>-sg
apiVersion: v1kind: Namespacemetadata: name: "dev-customized" annotations: { "opencontrail.org/network": '{"domain": "default-domain", "project": "demo", "name": "red"}' }
在項目default-domain:default中
在虛擬網(wǎng)絡(luò)上映射到自定義命名空間
從與該虛擬網(wǎng)絡(luò)關(guān)聯(lián)的IPAM上獲取地址
安全組?
在項目中映射到指定或默認的命名空間
在指定的虛擬網(wǎng)絡(luò)上
從與特定虛擬網(wǎng)絡(luò)關(guān)聯(lián)的IPAM上獲取地址
安全組?
3
Service
apiVersion: v1kind: ReplicationControllermetadata: name: web-qaspec: replicas: 2 selector: app: web-qa template: metadata: name: web-qa labels: app: web-qa spec: containers: - name: web image: docker.io/nginx imagePullPolicy: IfNotPresent
kind: ServiceapiVersion: v1metadata: name: web-qaspec: selector: app: web-qa ports: - protocol: TCP port: 80 targetPort: 80
參照以下內(nèi)容,創(chuàng)建LB VMI <cluster_project>:<service name>__<VMI UUID>。
SG k8s-default-<NS name>-default
SG k8s-default-<NS name>-sg
VN <cluster_project>:cluster-network
在VN cluster-network中從service-ipam分配LB IP地址(service IP)。不需要subnet UUID。
創(chuàng)建負載均衡器<cluster_project>:<service name>__<LB UUID>。
VIP是LB IP地址
VMI是LB VMI
提供者是“native”
創(chuàng)建浮動IP作為LB IP的子IP,地址相同,利用FIP支持端口NAT。
創(chuàng)建LB偵聽器<cluster_project>:<service name>__<LB UUID>-<protocol>-<port>-<LB listener UUID>
創(chuàng)建LB池<cluster_project>:<service name>__<LB UUID>-<protocol>-<port>-<LB listener UUID>
創(chuàng)建LB成員<cluster_project>:<pool>:<member UUID>
在FIP中設(shè)置端口映射。
將所有成員的VMI添加到FIP。
kind: ServiceapiVersion: v1metadata: name: web-qaspec: selector: app: web-qa ports: - protocol: TCP port: 80 targetPort: 80 type: LoadBalancer
附錄A 單租戶(Single-tenant)
{ "fq_name": [ "default-domain", "kubernetes", "pod-ipam" ], "uuid": "c9641741-c785-456e-845b-a14a253c3572", "ipam_subnet_method": "flat-subnet", "parent_type": "project", "perms2": { "owner": "None", "owner_access": 7, "global_access": 0, "share": [] }, "ipam_subnets": { "subnets": [ { "subnet": { "ip_prefix": "10.32.0.0", "ip_prefix_len": 12 }, "DNS_server_address": "10.47.255.253", "enable_dhcp": true, "created": null, "default_gateway": "10.47.255.254", "dns_nameservers": [], "dhcp_option_list": null, "subnet_uuid": null, "alloc_unit": 1, "last_modified": null, "host_routes": null, "addr_from_start": null, "subnet_name": null, "allocation_pools": [] } ] }, "id_perms": { "enable": true, "description": null, "creator": null, "created": "2017-12-27T18:45:33.957901", "uuid": { "uuid_mslong": 14511749470582293870, "uuid_lslong": 9537393975711511922 }, "user_visible": true, "last_modified": "2017-12-27T18:45:33.957901", "permissions": { "owner": "cloud-admin", "owner_access": 7, "other_access": 7, "group": "cloud-admin-group", "group_access": 7 } }, "display_name": "pod-ipam"}
{ "fq_name": [ "default-domain", "kubernetes", "service-ipam" ], "uuid": "526f554a-0bf4-47c6-a8e4-768a3f98cef4", "parent_type": "project", "perms2": { "owner": "None", "owner_access": 7, "global_access": 0, "share": [] }, "id_perms": { "enable": true, "description": null, "creator": null, "created": "2017-12-27T18:45:34.000690", "uuid": { "uuid_mslong": 5940060210041472966, "uuid_lslong": 12169982429206466292 }, "user_visible": true, "last_modified": "2017-12-27T18:45:34.000690", "permissions": { "owner": "cloud-admin", "owner_access": 7, "other_access": 7, "group": "cloud-admin-group", "group_access": 7 } }, "display_name": "service-ipam"}
{ "fq_name": [ "default-domain", "kubernetes", "k8s-default-dev-share-default" ], "uuid": "ad29de07-5ef6-4f55-86bb-52c44827c09d", "parent_type": "project", "perms2": { "owner": "46c31b9b-d21c-4c27-9445-6c94db948b6d", "owner_access": 7, "global_access": 0, "share": [] }, "security_group_id": 8000010, "id_perms": { "enable": true, "description": "Default security group", "creator": null, "created": "2018-01-12T09:02:15.110429", "uuid": { "uuid_mslong": 12477748365846007637, "uuid_lslong": 9708444424704868509 }, "user_visible": true, "last_modified": "2018-01-12T15:45:08.899388", "permissions": { "owner": "cloud-admin", "owner_access": 7, "other_access": 7, "group": "cloud-admin-group", "group_access": 7 } }, "security_group_entries": { "policy_rule": [ { "direction": ">", "protocol": "any", "dst_addresses": [ { "security_group": "local", "subnet": null, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "action_list": null, "created": null, "rule_uuid": "dc13bb48-e2a7-4c59-a0b8-740ecfcb9a2c", "dst_ports": [ { "end_port": 65535, "start_port": 0 } ], "application": [], "last_modified": null, "ethertype": "IPv4", "src_addresses": [ { "security_group": null, "subnet": { "ip_prefix": "0.0.0.0", "ip_prefix_len": 0 }, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "rule_sequence": null, "src_ports": [ { "end_port": 65535, "start_port": 0 } ] }, { "direction": ">", "protocol": "any", "dst_addresses": [ { "security_group": "local", "subnet": null, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "action_list": null, "created": null, "rule_uuid": "a84e2d98-2b8f-45ba-aa75-88494da73b11", "dst_ports": [ { "end_port": 65535, "start_port": 0 } ], "application": [], "last_modified": null, "ethertype": "IPv6", "src_addresses": [ { "security_group": null, "subnet": { "ip_prefix": "::", "ip_prefix_len": 0 }, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "rule_sequence": null, "src_ports": [ { "end_port": 65535, "start_port": 0 } ] }, { "direction": ">", "protocol": "any", "dst_addresses": [ { "security_group": null, "subnet": { "ip_prefix": "0.0.0.0", "ip_prefix_len": 0 }, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "action_list": null, "created": null, "rule_uuid": "b7752ec1-6037-4c7f-97a9-291893fbed64", "dst_ports": [ { "end_port": 65535, "start_port": 0 } ], "application": [], "last_modified": null, "ethertype": "IPv4", "src_addresses": [ { "security_group": "local", "subnet": null, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "rule_sequence": null, "src_ports": [ { "end_port": 65535, "start_port": 0 } ] }, { "direction": ">", "protocol": "any", "dst_addresses": [ { "security_group": null, "subnet": { "ip_prefix": "::", "ip_prefix_len": 0 }, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "action_list": null, "created": null, "rule_uuid": "ea5cd2a8-2d47-47c4-a9ab-390de2317246", "dst_ports": [ { "end_port": 65535, "start_port": 0 } ], "application": [], "last_modified": null, "ethertype": "IPv6", "src_addresses": [ { "security_group": "local", "subnet": null, "virtual_network": null, "subnet_list": [], "network_policy": null } ], "rule_sequence": null, "src_ports": [ { "end_port": 65535, "start_port": 0 } ] } ] }, "annotations": { "key_value_pair": [ { "key": "namespace", "value": "dev-share" }, { "key": "cluster", "value": "k8s-default" }, { "key": "kind", "value": "Namespace" }, { "key": "project", "value": "kubernetes" }, { "key": "name", "value": "k8s-default-dev-share-default" }, { "key": "owner", "value": "k8s" } ] }, "display_name": "k8s-default-dev-share-default"}
{ "fq_name": [ "default-domain", "kubernetes", "k8s-default-dev-share-sg" ], "uuid": "791f1c7e-a66e-4c47-ba05-409f00ee2c8e", "parent_type": "project", "perms2": { "owner": "46c31b9b-d21c-4c27-9445-6c94db948b6d", "owner_access": 7, "global_access": 0, "share": [] }, "security_group_id": 8000017, "id_perms": { "enable": true, "description": "Namespace security group", "creator": null, "created": "2018-01-12T09:02:15.236401", "uuid": { "uuid_mslong": 8727725933151013959, "uuid_lslong": 13404190917597736078 }, "user_visible": true, "last_modified": "2018-01-12T09:02:15.275407", "permissions": { "owner": "cloud-admin", "owner_access": 7, "other_access": 7, "group": "cloud-admin-group", "group_access": 7 } }, "display_name": "k8s-default-dev-share-sg", "annotations": { "key_value_pair": [ { "key": "namespace", "value": "dev-share" }, { "key": "cluster", "value": "k8s-default" },&n本文題目:TungstenFabric及Kubernetes集成解決是怎樣的
瀏覽路徑:http://www.rwnh.cn/article8/jijpip.html成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供動態(tài)網(wǎng)站、移動網(wǎng)站建設(shè)、關(guān)鍵詞優(yōu)化、品牌網(wǎng)站設(shè)計、微信公眾號、標簽優(yōu)化
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)