summaryrefslogtreecommitdiffstats
path: root/ansible_collections/cisco/nxos/.github
diff options
context:
space:
mode:
Diffstat (limited to 'ansible_collections/cisco/nxos/.github')
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/check_label.yml (renamed from ansible_collections/cisco/nxos/.github/workflows/ack.yml)10
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/codecoverage.yml3
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/draft_release.yml18
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/integration-test.yml38
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/push.yml27
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/release.yml4
-rw-r--r--ansible_collections/cisco/nxos/.github/workflows/tests.yml22
7 files changed, 75 insertions, 47 deletions
diff --git a/ansible_collections/cisco/nxos/.github/workflows/ack.yml b/ansible_collections/cisco/nxos/.github/workflows/check_label.yml
index fda595dc5..b120bfa32 100644
--- a/ansible_collections/cisco/nxos/.github/workflows/ack.yml
+++ b/ansible_collections/cisco/nxos/.github/workflows/check_label.yml
@@ -1,15 +1,11 @@
---
-# See https://github.com/ansible-community/devtools/blob/main/.github/workflows/ack.yml
-name: ack
-
+name: "Check label"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
-
on: # yamllint disable-line rule:truthy
pull_request_target:
types: [opened, labeled, unlabeled, synchronize]
-
jobs:
- ack:
- uses: ansible/devtools/.github/workflows/ack.yml@main
+ check_label:
+ uses: ansible/ansible-content-actions/.github/workflows/check_label.yaml@main
diff --git a/ansible_collections/cisco/nxos/.github/workflows/codecoverage.yml b/ansible_collections/cisco/nxos/.github/workflows/codecoverage.yml
index be2018590..034589bc1 100644
--- a/ansible_collections/cisco/nxos/.github/workflows/codecoverage.yml
+++ b/ansible_collections/cisco/nxos/.github/workflows/codecoverage.yml
@@ -1,8 +1,9 @@
---
-name: Code Coverage
+name: "Code coverage"
on: # yamllint disable-line rule:truthy
push:
+ branches: [main]
pull_request:
branches: [main]
diff --git a/ansible_collections/cisco/nxos/.github/workflows/draft_release.yml b/ansible_collections/cisco/nxos/.github/workflows/draft_release.yml
new file mode 100644
index 000000000..618f8a379
--- /dev/null
+++ b/ansible_collections/cisco/nxos/.github/workflows/draft_release.yml
@@ -0,0 +1,18 @@
+---
+name: "Draft release"
+concurrency:
+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
+ cancel-in-progress: true
+on: # yamllint disable-line rule:truthy
+ workflow_dispatch:
+env:
+ NAMESPACE: ${{ github.repository_owner }}
+ COLLECTION_NAME: nxos
+ ANSIBLE_COLLECTIONS_PATHS: ./
+jobs:
+ update_release_draft:
+ uses: ansible/ansible-content-actions/.github/workflows/draft_release.yaml@main
+ with:
+ repo: ${{ github.event.pull_request.head.repo.full_name }}
+ secrets:
+ BOT_PAT: ${{ secrets.BOT_PAT }}
diff --git a/ansible_collections/cisco/nxos/.github/workflows/integration-test.yml b/ansible_collections/cisco/nxos/.github/workflows/integration-test.yml
new file mode 100644
index 000000000..31375e1ca
--- /dev/null
+++ b/ansible_collections/cisco/nxos/.github/workflows/integration-test.yml
@@ -0,0 +1,38 @@
+name: Integration
+on:
+ pull_request_target:
+ branches: [main]
+ types:
+ - labeled
+ - opened
+ - reopened
+ - synchronize
+ paths:
+ - "plugins/**"
+ - "tests/integration/**"
+ workflow_dispatch:
+
+jobs:
+ safe-to-test:
+ if: >-
+ github.event.label.name == 'safe to test' ||
+ github.event.action != 'labeled'
+ uses: ansible-network/github_actions/.github/workflows/safe-to-test.yml@main
+ secrets:
+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
+ integration:
+ uses: ansible-network/github_actions/.github/workflows/integration.yml@main
+ needs:
+ - safe-to-test
+ with:
+ lab_title: cisco_nxos
+ network_os: cisco.nxos.nxos
+ pytest_addopts: "--color=yes -n 2 --log-level WARNING -vvv --role-excludes=snmp_server"
+ collection_pre_install: >-
+ git+https://github.com/ansible-collections/ansible.utils.git
+ git+https://github.com/ansible-collections/ansible.netcommon.git
+ secrets:
+ cml_ssh_password: ${{ secrets.CML_SSH_PASSWORD }}
+ virl_host: ${{ secrets.VIRL_HOST }}
+ virl_password: ${{ secrets.VIRL_PASSWORD }}
diff --git a/ansible_collections/cisco/nxos/.github/workflows/push.yml b/ansible_collections/cisco/nxos/.github/workflows/push.yml
deleted file mode 100644
index 771dd857a..000000000
--- a/ansible_collections/cisco/nxos/.github/workflows/push.yml
+++ /dev/null
@@ -1,27 +0,0 @@
----
-# push workflow is shared and expected to perform actions after a merge happens
-# on a maintenance branch (default or release). For example updating the
-# draft release-notes.
-# based on great work from
-# https://github.com/T-Systems-MMS/ansible-collection-icinga-director
-name: push
-
-concurrency:
- group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
- cancel-in-progress: true
-
-on: # yamllint disable-line rule:truthy
- workflow_dispatch:
-
-env:
- NAMESPACE: cisco
- COLLECTION_NAME: nxos
- ANSIBLE_COLLECTIONS_PATHS: ./
-
-jobs:
- update_release_draft:
- uses: ansible/devtools/.github/workflows/push_network.yml@main
- with:
- repo: ansible-collections/cisco.nxos
- secrets:
- BOT_PAT: ${{ secrets.BOT_PAT }}
diff --git a/ansible_collections/cisco/nxos/.github/workflows/release.yml b/ansible_collections/cisco/nxos/.github/workflows/release.yml
index eb04259d1..6dbb1aa39 100644
--- a/ansible_collections/cisco/nxos/.github/workflows/release.yml
+++ b/ansible_collections/cisco/nxos/.github/workflows/release.yml
@@ -1,12 +1,12 @@
---
-name: release
+name: "Release collection"
on: # yamllint disable-line rule:truthy
release:
types: [published]
jobs:
release:
- uses: ansible/devtools/.github/workflows/release_collection.yml@main
+ uses: ansible/ansible-content-actions/.github/workflows/release.yaml@main
with:
environment: release
secrets:
diff --git a/ansible_collections/cisco/nxos/.github/workflows/tests.yml b/ansible_collections/cisco/nxos/.github/workflows/tests.yml
index e9f92a2a0..5e8d914d4 100644
--- a/ansible_collections/cisco/nxos/.github/workflows/tests.yml
+++ b/ansible_collections/cisco/nxos/.github/workflows/tests.yml
@@ -1,5 +1,5 @@
---
-name: CI
+name: "CI"
concurrency:
group: ${{ github.head_ref || github.run_id }}
@@ -12,17 +12,18 @@ on: # yamllint disable-line rule:truthy
schedule:
- cron: '0 0 * * *'
-
jobs:
- ansible-lint:
- uses: ansible-network/github_actions/.github/workflows/ansible-lint.yml@main
changelog:
- uses: ansible-network/github_actions/.github/workflows/changelog.yml@main
+ uses: ansible/ansible-content-actions/.github/workflows/changelog.yaml@main
if: github.event_name == 'pull_request'
+ build-import:
+ uses: ansible/ansible-content-actions/.github/workflows/build_import.yaml@main
+ ansible-lint:
+ uses: ansible/ansible-content-actions/.github/workflows/ansible_lint.yaml@main
sanity:
- uses: ansible-network/github_actions/.github/workflows/sanity.yml@main
+ uses: ansible/ansible-content-actions/.github/workflows/sanity.yaml@main
unit-galaxy:
- uses: ansible-network/github_actions/.github/workflows/unit_galaxy.yml@main
+ uses: ansible/ansible-content-actions/.github/workflows/unit.yaml@main
unit-source:
uses: ansible-network/github_actions/.github/workflows/unit_source.yml@main
with:
@@ -32,19 +33,20 @@ jobs:
all_green:
if: ${{ always() }}
needs:
- - ansible-lint
- changelog
+ - build-import
- sanity
- unit-galaxy
- unit-source
+ - ansible-lint
runs-on: ubuntu-latest
steps:
- run: >-
python -c "assert 'failure' not in
set([
- '${{ needs.ansible-lint.result }}',
'${{ needs.changelog.result }}',
'${{ needs.sanity.result }}',
- '${{ needs.unit-galaxy.result }}',
+ '${{ needs.unit-galaxy.result }}'
+ '${{ needs.ansible-lint.result }}'
'${{ needs.unit-source.result }}'
])"