diff --git a/argo-workflows/ironic-to-nautobot-sync/sensors/ironic-to-nautobot-sensor.yaml b/argo-workflows/ironic-to-nautobot-sync/sensors/ironic-to-nautobot-sensor.yaml index b0849dc2..4a08ba68 100644 --- a/argo-workflows/ironic-to-nautobot-sync/sensors/ironic-to-nautobot-sensor.yaml +++ b/argo-workflows/ironic-to-nautobot-sync/sensors/ironic-to-nautobot-sensor.yaml @@ -59,10 +59,10 @@ spec: templates: - name: start steps: - - - name: synchronize-provision-state-to-nautobot + - - name: sync-provision-state-to-nautobot templateRef: - name: synchronize-provision-state-to-nautobot - template: synchronize-state + name: sync-provision-state-to-nautobot + template: sync-state arguments: parameters: - name: device_uuid diff --git a/argo-workflows/ironic-to-nautobot-sync/workflowtemplates/sync.yaml b/argo-workflows/ironic-to-nautobot-sync/workflowtemplates/sync.yaml index d59bc9e9..2d6fad89 100644 --- a/argo-workflows/ironic-to-nautobot-sync/workflowtemplates/sync.yaml +++ b/argo-workflows/ironic-to-nautobot-sync/workflowtemplates/sync.yaml @@ -1,6 +1,6 @@ apiVersion: argoproj.io/v1alpha1 metadata: - name: synchronize-provision-state-to-nautobot + name: sync-provision-state-to-nautobot annotations: workflows.argoproj.io/description: | Defined in `argo-workflows/ironic-to-nautobot-sensor/workflowtemplates/sync.yaml` @@ -8,11 +8,11 @@ kind: WorkflowTemplate spec: serviceAccountName: workflow templates: - - name: synchronize-state + - name: sync-state container: image: ghcr.io/rackerlabs/understack/ironic-nautobot-client:latest command: - - synchronize-provision-state + - sync-provision-state args: - --device-id - "{{workflow.parameters.device_uuid}}" diff --git a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-interfaces-to-ironic.yaml b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-interfaces-to-ironic.yaml similarity index 83% rename from argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-interfaces-to-ironic.yaml rename to argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-interfaces-to-ironic.yaml index f09b5b92..e6e05832 100644 --- a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-interfaces-to-ironic.yaml +++ b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-interfaces-to-ironic.yaml @@ -1,9 +1,9 @@ apiVersion: argoproj.io/v1alpha1 metadata: - name: synchronize-interfaces-to-ironic + name: sync-interfaces-to-ironic annotations: workflows.argoproj.io/description: | - Defined in `argo-workflows/sync-nb-server-to-ironic/synchronize-interfaces-to-ironic.yaml` + Defined in `argo-workflows/sync-nb-server-to-ironic/sync-interfaces-to-ironic.yaml` kind: WorkflowTemplate spec: arguments: @@ -18,7 +18,7 @@ spec: container: image: ghcr.io/rackerlabs/understack/ironic-nautobot-client:latest command: - - synchronize-interfaces + - sync-interfaces args: - --device-id - "{{inputs.parameters.device_id}}" diff --git a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-nb-server-to-ironic.yaml b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-nb-server-to-ironic.yaml index 7bd84b1b..247fae78 100644 --- a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-nb-server-to-ironic.yaml +++ b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-nb-server-to-ironic.yaml @@ -16,17 +16,17 @@ spec: templates: - name: main steps: - - - name: synchronize-server-to-ironic + - - name: sync-server-to-ironic templateRef: - name: synchronize-server-to-ironic - template: synchronize-server - - - name: synchronize-server-obm-creds + name: sync-server-to-ironic + template: sync-server + - - name: sync-server-obm-creds templateRef: - name: synchronize-obm-creds + name: sync-obm-creds template: main - - - name: synchronize-interfaces-to-ironic + - - name: sync-interfaces-to-ironic templateRef: - name: synchronize-interfaces-to-ironic + name: sync-interfaces-to-ironic template: main arguments: parameters: diff --git a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-obm-creds.yaml b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-obm-creds.yaml similarity index 83% rename from argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-obm-creds.yaml rename to argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-obm-creds.yaml index 2bbc8922..15d6c378 100644 --- a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-obm-creds.yaml +++ b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-obm-creds.yaml @@ -1,9 +1,9 @@ apiVersion: argoproj.io/v1alpha1 metadata: - name: synchronize-obm-creds + name: sync-obm-creds annotations: workflows.argoproj.io/description: | - Defined in `argo-workflows/sync-nb-server-to-ironic/synchronize-obm-creds.yaml` + Defined in `argo-workflows/sync-nb-server-to-ironic/sync-obm-creds.yaml` kind: WorkflowTemplate spec: entrypoint: main @@ -22,21 +22,21 @@ spec: parameters: - name: hostname value: '{{workflow.parameters.hostname}}' - - - name: synchronize-obm-creds - template: synchronize-obm-creds + - - name: sync-obm-creds + template: sync-obm-creds arguments: parameters: - name: obm value: "{{ steps.load-obm-creds.outputs.parameters.secret }}" - - name: synchronize-obm-creds + - name: sync-obm-creds inputs: parameters: - name: obm container: image: ghcr.io/rackerlabs/understack/ironic-nautobot-client:latest command: - - synchronize-obm-creds + - sync-obm-creds args: - "{{workflow.parameters.interface_update_event}}" volumeMounts: diff --git a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-server-to-ironic.yaml b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-server-to-ironic.yaml similarity index 77% rename from argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-server-to-ironic.yaml rename to argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-server-to-ironic.yaml index 5bdff181..c7fb110b 100644 --- a/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/synchronize-server-to-ironic.yaml +++ b/argo-workflows/sync-nb-server-to-ironic/workflowtemplates/sync-server-to-ironic.yaml @@ -1,9 +1,9 @@ apiVersion: argoproj.io/v1alpha1 metadata: - name: synchronize-server-to-ironic + name: sync-server-to-ironic annotations: workflows.argoproj.io/description: | - Defined in `argo-workflows/sync-nb-server-to-ironic/synchronize-server-to-ironic.yaml` + Defined in `argo-workflows/sync-nb-server-to-ironic/sync-server-to-ironic.yaml` kind: WorkflowTemplate spec: arguments: @@ -11,11 +11,11 @@ spec: - name: interface_update_event value: "{}" templates: - - name: synchronize-server + - name: sync-server container: image: ghcr.io/rackerlabs/understack/ironic-nautobot-client:latest command: - - synchronize-server + - sync-server args: - "{{workflow.parameters.interface_update_event}}" volumeMounts: diff --git a/argo-workflows/sync-srv-redfish-intfs-to-nb/docs/README.md b/argo-workflows/sync-srv-redfish-intfs-to-nb/docs/README.md index a7f6a57a..657bd381 100644 --- a/argo-workflows/sync-srv-redfish-intfs-to-nb/docs/README.md +++ b/argo-workflows/sync-srv-redfish-intfs-to-nb/docs/README.md @@ -4,7 +4,7 @@ The workflow templates in this folder are designed to create device interfaces i The process begins when a sensor detects updates to Nautobot OBM interfaces, prompting the get-obm-creds action to fetch the necessary OBM credentials. This step is crucial as it serves as a prerequisite for the other workflows in this folder. You can find examples of such dependencies in the `deps` folder. -Following this, the sensor initiates the `synchronize-interfaces-to-nautobot` workflow. This workflow obtains Redfish information from a server and uses it to create new device interfaces in Nautobot. +Following this, the sensor initiates the `sync-interfaces-to-nautobot` workflow. This workflow obtains Redfish information from a server and uses it to create new device interfaces in Nautobot. It is also worth noting that embedded/integrated interfaces are omitted for the purposes of the Undercloud project. diff --git a/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-interfaces-to-nautobot.yaml b/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-interfaces-to-nautobot.yaml index 25a84ee5..8c8441ae 100644 --- a/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-interfaces-to-nautobot.yaml +++ b/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-interfaces-to-nautobot.yaml @@ -13,7 +13,7 @@ spec: - name: oob_secret value: "{}" templates: - - name: synchronize-interfaces + - name: sync-interfaces container: image: ghcr.io/rackerlabs/understack/ironic-nautobot-client:latest command: diff --git a/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-srv-redfish-intfs-to-nb.yaml b/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-srv-redfish-intfs-to-nb.yaml index 555fc421..d205ac3c 100644 --- a/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-srv-redfish-intfs-to-nb.yaml +++ b/argo-workflows/sync-srv-redfish-intfs-to-nb/workflowtemplates/sync-srv-redfish-intfs-to-nb.yaml @@ -32,10 +32,10 @@ spec: parameters: - name: hostname value: "{{workflow.parameters.hostname}}" - - - name: synchronize-interfaces-to-nautobot + - - name: sync-interfaces-to-nautobot templateRef: name: sync-interfaces-to-nautobot - template: synchronize-interfaces + template: sync-interfaces arguments: parameters: - name: device_id diff --git a/python/understack-workflows/pyproject.toml b/python/understack-workflows/pyproject.toml index d6e67d17..be27d4e6 100644 --- a/python/understack-workflows/pyproject.toml +++ b/python/understack-workflows/pyproject.toml @@ -41,10 +41,10 @@ pytest-cov = "^5.0.0" pytest-mock = "^3.14.0" [tool.poetry.scripts] -synchronize-interfaces = "understack_workflows.main.synchronize_interfaces:main" -synchronize-obm-creds = "understack_workflows.main.synchronize_obm_creds:main" -synchronize-server = "understack_workflows.main.synchronize_server:main" -synchronize-provision-state = "understack_workflows.main.synchronize_provision_state:main" +sync-interfaces = "understack_workflows.main.sync_interfaces:main" +sync-obm-creds = "understack_workflows.main.sync_obm_creds:main" +sync-server = "understack_workflows.main.sync_server:main" +sync-provision-state = "understack_workflows.main.sync_provision_state:main" sync-nautobot-interfaces = "understack_workflows.main.sync_nautobot_interfaces:main" undersync-switch = "understack_workflows.main.undersync_switch:main" undersync-device = "understack_workflows.main.undersync_device:main" diff --git a/python/understack-workflows/tests/test_synchronize_provision_state.py b/python/understack-workflows/tests/test_sync_provison_state.py similarity index 88% rename from python/understack-workflows/tests/test_synchronize_provision_state.py rename to python/understack-workflows/tests/test_sync_provison_state.py index d3453be8..c02a3036 100644 --- a/python/understack-workflows/tests/test_synchronize_provision_state.py +++ b/python/understack-workflows/tests/test_sync_provison_state.py @@ -1,7 +1,7 @@ import pytest -from understack_workflows.main.synchronize_provision_state import argument_parser -from understack_workflows.main.synchronize_provision_state import do_action +from understack_workflows.main.sync_provision_state import argument_parser +from understack_workflows.main.sync_provision_state import do_action @pytest.fixture diff --git a/python/understack-workflows/understack_workflows/main/synchronize_interfaces.py b/python/understack-workflows/understack_workflows/main/sync_interfaces.py similarity index 100% rename from python/understack-workflows/understack_workflows/main/synchronize_interfaces.py rename to python/understack-workflows/understack_workflows/main/sync_interfaces.py diff --git a/python/understack-workflows/understack_workflows/main/synchronize_obm_creds.py b/python/understack-workflows/understack_workflows/main/sync_obm_creds.py similarity index 100% rename from python/understack-workflows/understack_workflows/main/synchronize_obm_creds.py rename to python/understack-workflows/understack_workflows/main/sync_obm_creds.py diff --git a/python/understack-workflows/understack_workflows/main/synchronize_provision_state.py b/python/understack-workflows/understack_workflows/main/sync_provision_state.py similarity index 100% rename from python/understack-workflows/understack_workflows/main/synchronize_provision_state.py rename to python/understack-workflows/understack_workflows/main/sync_provision_state.py diff --git a/python/understack-workflows/understack_workflows/main/synchronize_server.py b/python/understack-workflows/understack_workflows/main/sync_server.py similarity index 100% rename from python/understack-workflows/understack_workflows/main/synchronize_server.py rename to python/understack-workflows/understack_workflows/main/sync_server.py