diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index bd4ab20..e12ee15 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -86,7 +86,7 @@ jobs: - name: Update the glaxay.yml version run: | - sed -ie 's/version:.*/version: ${{ env.VERSION }}/' galaxy.yml + sed -i -e 's/version:.*/version: ${{ env.VERSION }}/' galaxy.yml - name: Determine if a PR is necessary run: git diff --no-ext-diff --quiet --exit-code diff --git a/.github/workflows/safe_to_test.yml b/.github/workflows/safe_to_test.yml new file mode 100644 index 0000000..ded86c4 --- /dev/null +++ b/.github/workflows/safe_to_test.yml @@ -0,0 +1,40 @@ +name: test + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +on: + pull_request_target: + branches: [main] + types: + - labeled + - opened + - reopened + - synchronize + 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 }} + + tox-ansible: + uses: tox-dev/tox-ansible/.github/workflows/run.yml@main + needs: + - safe-to-test + + tox-ansible-passed: + if: ${{ always() }} + needs: + - tox-ansible + runs-on: ubuntu-latest + steps: + - run: >- + python -c "assert set([ + '${{ needs.tox-ansible.result }}', + ]) == {'success'}" diff --git a/.github/workflows/token_refresh.yml b/.github/workflows/token_refresh.yml index 54de6b8..6bae52b 100644 --- a/.github/workflows/token_refresh.yml +++ b/.github/workflows/token_refresh.yml @@ -1,5 +1,4 @@ -name: Token refresh cron - +name: Refresh the Automation Hub token on: schedule: - cron: '0 0 * * *' @@ -7,13 +6,8 @@ on: jobs: refresh: - runs-on: ubuntu-latest - environment: ah - steps: - - name: Refresh to AH token - run: >- - curl https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token - -d grant_type=refresh_token - -d client_id=cloud-services - -d refresh_token="${{ secrets.AH_TOKEN }}" - --fail --silent --show-error --output /dev/null + uses: ansible/devtools/.github/workflows/ah_token_refresh.yml@main + with: + environment: release + secrets: + ah_token: ${{ secrets.AH_TOKEN }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ceebfe5..54f52e2 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ repos: - repo: https://github.com/ansible-network/collection_prep rev: 1.1.1 hooks: - - id: autoversion + # - id: autoversion - id: update-docs - repo: https://github.com/pre-commit/pre-commit-hooks diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 53be36e..bd62fbb 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -5,6 +5,15 @@ Ansible Utils Collection Release Notes .. contents:: Topics +v2.10.2 +======= + +Minor Changes +------------- + +- validate - Add option `check_format` for the jsonschema engine to disable JSON Schema format checking. +- validate - Add support for JSON Schema draft 2019-09 and 2020-12 as well as automatically choosing the draft from the `$schema` field of the criteria. + v2.9.0 ====== diff --git a/changelogs/cli_parse_fix.yaml b/changelogs/cli_parse_fix.yaml deleted file mode 100644 index aec41f5..0000000 --- a/changelogs/cli_parse_fix.yaml +++ /dev/null @@ -1,4 +0,0 @@ ---- -bugfixes: - - Fix ansible.utils.cli_parse action plugin to support old cli_parse sub-plugin - structure in ansible.netcommon collection. diff --git a/changelogs/fragments/netaddr_error.yml b/changelogs/fragments/netaddr_error.yml deleted file mode 100644 index 823c7f8..0000000 --- a/changelogs/fragments/netaddr_error.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- -trivial: - - fixed netaddr error message to give better clarity that the package is missing diff --git a/changelogs/fragments/pre-commit.yaml b/changelogs/fragments/pre-commit.yaml deleted file mode 100644 index 7bed354..0000000 --- a/changelogs/fragments/pre-commit.yaml +++ /dev/null @@ -1,3 +0,0 @@ ---- -trivial: - - Update pre-commit config to add autoversion hook diff --git a/changelogs/fragments/validate_jsonschema_update.yaml b/changelogs/fragments/validate_jsonschema_update.yaml deleted file mode 100644 index 1f449b2..0000000 --- a/changelogs/fragments/validate_jsonschema_update.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -minor_changes: - - validate - Add support for JSON Schema draft 2019-09 and 2020-12 as well as automatically choosing the draft - from the `$schema` field of the criteria. - - validate - Add option `check_format` for the jsonschema engine to disable JSON Schema format checking. diff --git a/galaxy.yml b/galaxy.yml index 06fe616..5fa2234 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -13,4 +13,4 @@ issues: https://github.com/ansible-collections/ansible.utils/issues tags: [linux, networking, security, cloud, utilities, data, validation, utils] # NOTE(pabelanger): We create an empty version key to keep ansible-galaxy # happy. We dynamically inject version info based on git information. -version: 2.10.0-dev +version: 2.10.2