Skip to content

Commit 6a616ca

Browse files
Addressed review comments
Signed-off-by: Marikkannu, Suresh <[email protected]>
1 parent c94c06c commit 6a616ca

File tree

7 files changed

+3
-191
lines changed

7 files changed

+3
-191
lines changed

Makefile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export EXTRA_VARS ?= "@$(5GC_ROOT_DIR)/vars/main.yml"
1919

2020
#### b. Provision k8s ####
2121
5gc-install: 5gc-router-install 5gc-sriov-install 5gc-core-install
22-
5gc-uninstall: 5gc-core-uninstall 5gc-sriov-uninstall 5gc-router-uninstall
22+
5gc-uninstall: 5gc-core-uninstall 5gc-router-uninstall
2323

2424
#### c. Provision router ####
2525
5gc-router-install:
@@ -33,9 +33,6 @@ export EXTRA_VARS ?= "@$(5GC_ROOT_DIR)/vars/main.yml"
3333
5gc-sriov-install:
3434
ansible-playbook -i $(HOSTS_INI_FILE) $(5GC_ROOT_DIR)/sriov.yml --tags install \
3535
--extra-vars "ROOT_DIR=$(ROOT_DIR)" --extra-vars $(EXTRA_VARS)
36-
5gc-sriov-uninstall:
37-
ansible-playbook -i $(HOSTS_INI_FILE) $(5GC_ROOT_DIR)/sriov.yml --tags uninstall \
38-
--extra-vars "ROOT_DIR=$(ROOT_DIR)" --extra-vars $(EXTRA_VARS)
3936

4037
#### e. Provision core ####
4138
5gc-core-install:

roles/core/templates/sdcore-5g-sriov-values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ omec-sub-provision:
110110
cfgFiles:
111111
simapp.yaml:
112112
configuration:
113-
provision-network-slice: {{ core.standalone }} # if enabled, Device Groups & Slices configure by simapp
113+
provision-network-slice: {{ core.standalone | string }} # if enabled, Device Groups & Slices configure by simapp
114114
sub-provision-endpt:
115115
addr: webui.omec.svc.cluster.local # subscriber configuation endpoint.
116116
# sub-proxy-endpt: # used if subscriber proxy is enabled in the ROC.

roles/sriov/tasks/install.yml

Lines changed: 1 addition & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# TODO: running on master node for now (fix to run on multiple nodes)
44

5-
- name: check VF resources and bind them to vfio-pci
5+
- name: check VF resources
66
block:
77
- name: Get number of VF's available for the "{{ core.data_iface }}"
88
shell: ip link show "{{ core.data_iface }}" | grep -c vf
@@ -17,57 +17,4 @@
1717
that:
1818
- vf_status.stdout | int >= 2
1919

20-
- name: Get number of VF's attached to vfio-pci driver
21-
shell: driverctl -v list-overrides | grep 'vfio-pci' | wc -l
22-
register: vf_status
23-
changed_when: false
24-
25-
- debug:
26-
var=vf_status.stdout
27-
28-
- name: verify at least two VF resourses attached to vfio-pci driver
29-
ansible.builtin.assert:
30-
that:
31-
- vf_status.stdout | int >= 2
32-
33-
when: inventory_hostname in groups['master_nodes'] and core.upf.mode == "dpdk"
34-
35-
- name: deploy sriov plugins
36-
block:
37-
- name: copy sriov-device-plugin.yaml to /tmp/sriov-device-plugin.yaml
38-
template:
39-
src: roles/sriov/templates/sriov-device-plugin.yaml
40-
dest: "/tmp/sriov-device-plugin.yaml"
41-
42-
- name: copy sriov-device-plugin-config.yaml to /tmp/sriov-device-plugin-config.yaml
43-
template:
44-
src: roles/sriov/templates/sriov-device-plugin-config.yaml
45-
dest: "/tmp/sriov-device-plugin-config.yaml"
46-
47-
- name: update proper data interface name in /tmp/sriov-device-plugin-config.yaml
48-
shell: sed -i -e "s/PFDEV/{{ core.data_iface }}/g" /tmp/sriov-device-plugin-config.yaml
49-
50-
- name: apply /tmp/sriov-device-plugin.yaml
51-
shell: kubectl apply -f /tmp/sriov-device-plugin.yaml
52-
53-
- name: apply /tmp/sriov-device-plugin-config.yaml
54-
shell: kubectl apply -f /tmp/sriov-device-plugin-config.yaml
55-
56-
- name: Get Sriov Pods Status
57-
shell: kubectl get pods -A | grep sriov
58-
register: pod_status
59-
changed_when: false
60-
61-
- name: restart sriov Pod
62-
shell: |
63-
while IFS= read -r line; do
64-
name=$(echo "$line" | awk '{print $2}')
65-
status=$(echo "$line" | awk '{print $4}')
66-
67-
kubectl delete pod "$name"
68-
done <<< "{{ pod_status.stdout }}"
69-
args:
70-
executable: /bin/bash
71-
- pause:
72-
seconds: 10
7320
when: inventory_hostname in groups['master_nodes'] and core.upf.mode == "dpdk"

roles/sriov/tasks/main.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,3 @@
33
- name: install 5gc/sriov
44
import_tasks: roles/sriov/tasks/install.yml
55
tags: install
6-
7-
- name: uninstall 5gc/sriov
8-
import_tasks: roles/sriov/tasks/uninstall.yml
9-
tags: uninstall

roles/sriov/tasks/uninstall.yml

Lines changed: 0 additions & 12 deletions
This file was deleted.

roles/sriov/templates/sriov-device-plugin-config.yaml

Lines changed: 0 additions & 32 deletions
This file was deleted.

roles/sriov/templates/sriov-device-plugin.yaml

Lines changed: 0 additions & 84 deletions
This file was deleted.

0 commit comments

Comments
 (0)