Skip to content

Commit 0984522

Browse files
committed
Configuring nicMappings for OVN gateways
Related to OSPRH-17761
1 parent 4753cef commit 0984522

File tree

5 files changed

+34
-0
lines changed

5 files changed

+34
-0
lines changed

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,11 @@ test-swift-migration:
5959
mkdir -p tests/logs
6060
ANSIBLE_CONFIG=$(TEST_CONFIG) ansible-playbook -v -i $(TEST_INVENTORY) -e @$(TEST_SECRETS) -e @$(TEST_VARS) $(TEST_ARGS) tests/playbooks/test_swift_migration.yaml 2>&1 | tee $(TEST_OUTFILE)
6161

62+
test-ocp-as-gw: TEST_OUTFILE ?= tests/logs/test_ocp_as_gw_out_$(shell date +%FT%T%Z).log
63+
test-ocp-as-gw: ## Launch test suite related to the ocp gateways
64+
mkdir -p tests/logs
65+
ANSIBLE_CONFIG=$(TEST_CONFIG) ansible-playbook -v -i $(TEST_INVENTORY) -e @$(TEST_SECRETS) -e @$(TEST_VARS) $(TEST_ARGS) tests/playbooks/test_ocp_as_gw.yaml 2>&1 | tee $(TEST_OUTFILE)
66+
6267
test-rollback-minimal: TEST_OUTFILE ?= tests/logs/test_rollback_minimal_out_$(shell date +%FT%T%Z).log
6368
test-rollback-minimal:
6469
mkdir -p tests/logs
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
- name: Configuring nicMappings for OCP gateways
2+
hosts: local
3+
gather_facts: false
4+
force_handlers: true
5+
module_defaults:
6+
ansible.builtin.shell:
7+
executable: /bin/bash
8+
roles:
9+
- role: ocp_as_gw
10+
tags:
11+
- ocp_as_gw
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
ironic_adoption: false
2+
3+
ovn_nic_mapping_patch: |
4+
spec:
5+
ovn:
6+
enabled: true
7+
template:
8+
ovnController:
9+
nicMappings:
10+
datacentre: ocpbr
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dependencies:
2+
- role: common_defaults
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
- name: Add OVN nicMappings for OpenShift as gateway
2+
when: not ironic_adoption|bool
3+
ansible.builtin.shell: |
4+
{{ shell_header }}
5+
{{ oc_header }}
6+
oc patch openstackcontrolplane openstack --type=merge --patch '{{ ovn_nic_mapping_patch }}'

0 commit comments

Comments
 (0)