aboutsummaryrefslogtreecommitdiffstats
path: root/resources/tools/testbed-setup/ansible/roles/sut/tasks
diff options
context:
space:
mode:
authorStanislav Chlebec <stanislav.chlebec@pantheon.tech>2019-01-16 15:42:36 +0100
committerPeter Mikus <pmikus@cisco.com>2019-02-19 15:44:25 +0000
commitab596c32fdda48aa8140f428710b98d47baf9cae (patch)
tree103093102eb82f40a583643067dcadf114e5e369 /resources/tools/testbed-setup/ansible/roles/sut/tasks
parentd1589ad74e515757fb12cf8a5f976282924afe13 (diff)
Ansible testbed setup for Taishan testbed
Change-Id: I4b42aa5bf7635ade95f81c0c92a6ff1bf43d3fa0 Signed-off-by: Stanislav Chlebec <stanislav.chlebec@pantheon.tech> Signed-off-by: juraj.linkes <juraj.linkes@pantheon.tech>
Diffstat (limited to 'resources/tools/testbed-setup/ansible/roles/sut/tasks')
-rw-r--r--resources/tools/testbed-setup/ansible/roles/sut/tasks/main.yaml8
-rw-r--r--resources/tools/testbed-setup/ansible/roles/sut/tasks/taishan_workaround.yaml30
-rw-r--r--resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu.yaml (renamed from resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu_x86_64.yaml)2
3 files changed, 37 insertions, 3 deletions
diff --git a/resources/tools/testbed-setup/ansible/roles/sut/tasks/main.yaml b/resources/tools/testbed-setup/ansible/roles/sut/tasks/main.yaml
index 0ecdcdba3b..f5a2dd86ad 100644
--- a/resources/tools/testbed-setup/ansible/roles/sut/tasks/main.yaml
+++ b/resources/tools/testbed-setup/ansible/roles/sut/tasks/main.yaml
@@ -2,8 +2,12 @@
# file: roles/sut/tasks/main.yaml
- name: Ubuntu specific
- import_tasks: ubuntu_x86_64.yaml
- when: ansible_distribution|lower == 'ubuntu' and ansible_machine == 'x86_64'
+ import_tasks: ubuntu.yaml
+ when: ansible_distribution|lower == 'ubuntu'
+
+- name: Taishan aarch64 specific
+ import_tasks: taishan_workaround.yaml
+ when: taishan_workaround is defined
- name: Copy 80-vpp.conf
file:
diff --git a/resources/tools/testbed-setup/ansible/roles/sut/tasks/taishan_workaround.yaml b/resources/tools/testbed-setup/ansible/roles/sut/tasks/taishan_workaround.yaml
new file mode 100644
index 0000000000..e262e7288b
--- /dev/null
+++ b/resources/tools/testbed-setup/ansible/roles/sut/tasks/taishan_workaround.yaml
@@ -0,0 +1,30 @@
+---
+# file: roles/sut/tasks/taishan_workaround.yaml
+
+- name: Ensure systemd directory exists
+ file:
+ path: "/etc/systemd/system"
+ state: "directory"
+ owner: "root"
+ group: "root"
+ mode: "0755"
+ tags: taishan-workaround
+
+- name: Copy systemd numa config unit file
+ template:
+ src: "files/taishan_workaround.service"
+ dest: "/etc/systemd/system/nic-numa-config.service"
+ owner: "root"
+ group: "root"
+ mode: "0644"
+ register: numa_config_service
+ tags: taishan-workaround
+
+- name: Reload systemd daemon
+ command: "systemctl daemon-reload"
+ when: (numa_config_service and numa_config_service is changed)
+ tags: taishan-workaround
+
+- name: Enable numa config service
+ command: "systemctl enable nic-numa-config.service"
+ tags: taishan-workaround
diff --git a/resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu_x86_64.yaml b/resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu.yaml
index 38946b6bbb..824f0926b5 100644
--- a/resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu_x86_64.yaml
+++ b/resources/tools/testbed-setup/ansible/roles/sut/tasks/ubuntu.yaml
@@ -1,5 +1,5 @@
---
-# file: roles/sut/tasks/ubuntu_x86_64.yaml
+# file: roles/sut/tasks/ubuntu.yaml
- name: Install DKMS
apt: