Rename and restructure the collection. #25
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
env: | |
COLORTERM: 'yes' | |
TERM: 'xterm-256color' | |
PYTEST_ADDOPTS: '--color=yes' | |
jobs: | |
test: | |
name: CI test | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the codebase. | |
uses: actions/checkout@v4 | |
- name: Set up Python3. | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Install yamllint | |
run: | | |
python -m pip install --upgrade pip | |
pip install yamllint 'molecule>=24.2.0' 'molecule-plugins[docker]>=23.5.3' 'ansible-core<2.16' ansible-lint | |
python -m pip install 'requests<2.32' | |
- name: Prepare ansible.cfg and reqs | |
run: | | |
echo "[galaxy] | |
server_list = automation_hub, release_galaxy | |
[galaxy_server.automation_hub] | |
url=https://console.redhat.com/api/automation-hub/content/published/ | |
auth_url=https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token | |
token = ${{ secrets.ANSIBLE_GALAXY_TOKEN }} | |
[galaxy_server.release_galaxy] | |
url=https://galaxy.ansible.com/"> ansible.cfg | |
ansible-galaxy collection install -r molecule/requirements.yml | |
- name: Linter | |
run: | | |
ansible-lint --version | |
ansible-lint --offline | |
- name: Run molecule test | |
run: | | |
molecule --version | |
molecule test | |
env: | |
PROD_JBOSSNETWORK_API_CLIENTID: '${{ secrets.PROD_JBOSSNETWORK_API_CLIENTID }}' | |
PROD_JBOSSNETWORK_API_SECRET: '${{ secrets.PROD_JBOSSNETWORK_API_SECRET }}' |