From b5e4a8178fce6ab9d60f1c4e2cd9ec53cbd5d2f8 Mon Sep 17 00:00:00 2001 From: Ritu Sood Date: Wed, 14 Aug 2019 19:41:37 +0000 Subject: Add support for Network Operator ovn4nfvk8s plugin now uses operator sdk and controller runtime. It now includes support for Network operator. This patch includes changes needed in KUD for that. Signed-off-by: Ritu Sood Issue-ID: MULTICLOUD-684 Change-Id: I63dc971e257067c69c70a8996eaffd1a9d8a4c2c --- kud/demo/firewall/charts/packetgen/templates/deployment.yaml | 4 ++-- kud/demo/firewall/charts/sink/templates/deployment.yaml | 4 ++-- kud/demo/firewall/templates/deployment.yaml | 4 ++-- kud/demo/firewall/templates/onap-private-net.yaml | 11 ++++++----- kud/demo/firewall/templates/protected-private-net.yaml | 11 ++++++----- kud/demo/firewall/templates/unprotected-private-net.yaml | 11 ++++++----- 6 files changed, 24 insertions(+), 21 deletions(-) (limited to 'kud/demo/firewall') diff --git a/kud/demo/firewall/charts/packetgen/templates/deployment.yaml b/kud/demo/firewall/charts/packetgen/templates/deployment.yaml index 3538a6e7..63b10ea7 100644 --- a/kud/demo/firewall/charts/packetgen/templates/deployment.yaml +++ b/kud/demo/firewall/charts/packetgen/templates/deployment.yaml @@ -44,10 +44,10 @@ spec: - wget -O - https://git.onap.org/multicloud/k8s/plain/kud/tests/vFW/packetgen | sudo -E bash VirtletRootVolumeSize: 5Gi k8s.v1.cni.cncf.io/networks: '[{"name": {{ .Values.global.ovnMultusNetworkName | quote }}, "namespace": "default"}]' - ovnNetwork: '[ + k8s.plugin.opnfv.org/nfn-network: '{ "type": "ovn4nfv", "interface":[ { "name": {{ .Values.global.unprotectedNetworkName | quote }}, "ipAddress": {{ .Values.global.vpgPrivateIp0 | quote }}, "interface": "eth1" , "defaultGateway": "false"}, { "name": {{ .Values.global.onapPrivateNetworkName | quote }}, "ipAddress": {{ .Values.global.vpgPrivateIp1 | quote }}, "interface": "eth2" , "defaultGateway": "false"} - ]' + ]}' kubernetes.io/target-runtime: virtlet.cloud spec: affinity: diff --git a/kud/demo/firewall/charts/sink/templates/deployment.yaml b/kud/demo/firewall/charts/sink/templates/deployment.yaml index 57894010..b2119c10 100644 --- a/kud/demo/firewall/charts/sink/templates/deployment.yaml +++ b/kud/demo/firewall/charts/sink/templates/deployment.yaml @@ -19,10 +19,10 @@ spec: release: {{ .Release.Name }} annotations: k8s.v1.cni.cncf.io/networks: '[{"name": {{ .Values.global.ovnMultusNetworkName | quote }}, "namespace": "default"}]' - ovnNetwork: '[ + k8s.plugin.opnfv.org/nfn-network: '{ "type": "ovn4nfv", "interface": [ { "name": {{ .Values.global.protectedNetworkName | quote }}, "ipAddress": {{ .Values.global.vsnPrivateIp0 | quote }}, "interface": "eth1", "defaultGateway": "false" }, { "name": {{ .Values.global.onapPrivateNetworkName | quote }}, "ipAddress": {{ .Values.global.vsnPrivateIp1 | quote }}, "interface": "eth2" , "defaultGateway": "false"} - ]' + ]}' spec: containers: - name: {{ .Chart.Name }} diff --git a/kud/demo/firewall/templates/deployment.yaml b/kud/demo/firewall/templates/deployment.yaml index b273d287..060f6cd2 100644 --- a/kud/demo/firewall/templates/deployment.yaml +++ b/kud/demo/firewall/templates/deployment.yaml @@ -42,11 +42,11 @@ spec: - wget -O - https://git.onap.org/multicloud/k8s/plain/kud/tests/vFW/firewall | sudo -E bash VirtletRootVolumeSize: 5Gi k8s.v1.cni.cncf.io/networks: '[{"name": {{ .Values.global.ovnMultusNetworkName | quote }}, "namespace": "default"}]' - ovnNetwork: '[ + k8s.plugin.opnfv.org/nfn-network: '{ "type": "ovn4nfv", "interface": [ { "name": {{ .Values.global.unprotectedNetworkName | quote }}, "ipAddress": {{ .Values.global.vfwPrivateIp0 | quote }}, "interface": "eth1" , "defaultGateway": "false"}, { "name": {{ .Values.global.protectedNetworkName | quote }}, "ipAddress": {{ .Values.global.vfwPrivateIp1 | quote }}, "interface": "eth2", "defaultGateway": "false" }, { "name": {{ .Values.global.onapPrivateNetworkName | quote }}, "ipAddress": {{ .Values.global.vfwPrivateIp2 | quote }}, "interface": "eth3" , "defaultGateway": "false"} - ]' + ]}' kubernetes.io/target-runtime: virtlet.cloud spec: affinity: diff --git a/kud/demo/firewall/templates/onap-private-net.yaml b/kud/demo/firewall/templates/onap-private-net.yaml index e4079e2c..245466cf 100644 --- a/kud/demo/firewall/templates/onap-private-net.yaml +++ b/kud/demo/firewall/templates/onap-private-net.yaml @@ -1,9 +1,10 @@ -apiVersion: v1 +apiVersion: k8s.plugin.opnfv.org/v1alpha1 kind: Network metadata: name: {{ .Values.global.onapPrivateNetworkName }} spec: - cnitype : ovn4nfvk8s - name: {{ .Values.global.onapPrivateNetworkName }} - subnet: {{ .Values.global.onapPrivateNetCidr }} - gateway: {{ .Values.global.onapPrivateNetGw }} + cniType : ovn4nfv + ipv4Subnets: + - name: subnet1 + subnet: {{ .Values.global.onapPrivateNetCidr }} + gateway: {{ .Values.global.onapPrivateNetGw }} diff --git a/kud/demo/firewall/templates/protected-private-net.yaml b/kud/demo/firewall/templates/protected-private-net.yaml index 33724472..dcac386a 100644 --- a/kud/demo/firewall/templates/protected-private-net.yaml +++ b/kud/demo/firewall/templates/protected-private-net.yaml @@ -1,9 +1,10 @@ -apiVersion: v1 +apiVersion: k8s.plugin.opnfv.org/v1alpha1 kind: Network metadata: name: {{ .Values.global.protectedNetworkName }} spec: - cnitype : ovn4nfvk8s - name: {{ .Values.global.protectedNetworkName }} - subnet: {{ .Values.global.protectedNetCidr }} - gateway: {{ .Values.global.protectedNetGw }} + cniType : ovn4nfv + ipv4Subnets: + - name: subnet1 + subnet: {{ .Values.global.protectedNetCidr }} + gateway: {{ .Values.global.protectedNetGw }} diff --git a/kud/demo/firewall/templates/unprotected-private-net.yaml b/kud/demo/firewall/templates/unprotected-private-net.yaml index 2c192598..3bdc3381 100644 --- a/kud/demo/firewall/templates/unprotected-private-net.yaml +++ b/kud/demo/firewall/templates/unprotected-private-net.yaml @@ -1,9 +1,10 @@ -apiVersion: v1 +apiVersion: k8s.plugin.opnfv.org/v1alpha1 kind: Network metadata: name: {{ .Values.global.unprotectedNetworkName }} spec: - cnitype : ovn4nfvk8s - name: {{ .Values.global.unprotectedNetworkName }} - subnet: {{ .Values.global.protectedPrivateNetCidr }} - gateway: {{ .Values.global.protectedPrivateNetGw }} + cniType : ovn4nfv + ipv4Subnets: + - name: subnet1 + subnet: {{ .Values.global.protectedPrivateNetCidr }} + gateway: {{ .Values.global.protectedPrivateNetGw }} -- cgit 1.2.3-korg