Skip to content

[AAP-57909] Fix for the custom role team assignment #644

[AAP-57909] Fix for the custom role team assignment

[AAP-57909] Fix for the custom role team assignment #644

Workflow file for this run

---
name: linting
env:
LC_ALL: "C.UTF-8" # prevent ERROR: Ansible could not initialize the preferred locale: unsupported locale setting
on:
pull_request:
push:
branches: [devel]
jobs:
common-tests:
name: ${{ matrix.tests.name }}
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
strategy:
fail-fast: false
matrix:
tests:
- name: flake8
command: check_flake8
- name: black
command: check_black
- name: isort
command: check_isort
steps:
- name: Install make
run: sudo apt install make
- uses: actions/checkout@v2
- name: Install python 3.11
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install requirements
run: pip3.11 install -r requirements/requirements_dev.txt
- name: Run check ${{ matrix.tests.name }}
run: make ${{ matrix.tests.command }}
sanity:
name: Run ansible-test sanity
runs-on: ubuntu-latest
env:
HEADLESS: "yes"
timeout-minutes: 30
strategy:
fail-fast: false
matrix:
ansible:
- stable-2.16
- stable-2.17
- stable-2.18
- stable-2.19
steps:
- uses: actions/checkout@v3
- name: Perform sanity testing
uses: ansible-community/ansible-test-gh-action@release/v1
with:
ansible-core-version: ${{ matrix.ansible }}
collection-root: .
testing-type: sanity
target-python-version: 3.11
- name: Upload gateway jUnit test reports to the unified dashboard
if: >-
!cancelled()
&& steps.make-run.outputs.test-result-files != ''
&& github.event_name == 'push'
&& env.UPSTREAM_REPOSITORY_ID == github.repository_id
&& github.ref_name == github.event.repository.default_branch
run: |
for junit_file in $(echo '${{ steps.make-run.outputs.test-result-files }}' | sed 's/,/ /')
do
curl \
-v \
--user "${{ vars.PDE_ORG_RESULTS_AGGREGATOR_UPLOAD_USER }}:${{ secrets.PDE_ORG_RESULTS_UPLOAD_PASSWORD }}" \
--form "xunit_xml=@${junit_file}" \
--form "component_name=gateway" \
--form "git_commit_sha=${{ github.sha }}" \
--form "git_repository_url=https://github.com/${{ github.repository }}" \
"${{ vars.PDE_ORG_RESULTS_AGGREGATOR_UPLOAD_URL }}/api/results/upload/"
done
docs:
name: Check module doc strings
runs-on: ubuntu-latest
env:
HEADLESS: "yes"
steps:
- name: Install python 3.11
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install requirements
run: pip3.11 install --upgrade ansible
- uses: actions/checkout@v3
- name: Run ansible-doc
run: make collection-docs
- name: Get ansible-doc version
run: ansible-doc --version
if: failure()
ansible-lint:
name: Run ansible-lint
runs-on: ubuntu-latest
env:
HEADLESS: "yes"
steps:
- name: Install python 3.11
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install requirements
run: pip3.11 install --upgrade ansible-lint
- uses: actions/checkout@v3
- name: Run ansible-lint
run: make collection-lint
- name: Get ansible-lint version
run: ansible-lint --version
if: failure()
build-import:
name: Build collection and run galaxy importer check
uses: ansible/ansible-content-actions/.github/workflows/build_import.yaml@main
...