File tree Expand file tree Collapse file tree 1 file changed +19
-3
lines changed Expand file tree Collapse file tree 1 file changed +19
-3
lines changed Original file line number Diff line number Diff line change 5353 - name : Checkout
5454 uses : actions/checkout@v3
5555
56+ - name : Install ansible-lint
57+ run : pip install ansible-lint
58+
59+ - name : Install Ansible Role Requirements
60+ run : |
61+ if test -f "requirements.yml"; then
62+ ansible-galaxy install -r requirements.yml
63+ fi
64+
5665 - name : Ansible Lint
57- uses : ansible-community/ansible- lint-action@v6
66+ run : ansible-lint .
5867
5968 test :
6069 name : Molecule
7685 # Writing molecule config for docker
7786 echo "${{ inputs.molecule-config}}" > molecule/github/molecule.yml
7887
88+ # Copy test dependencies if they exist
89+ if test -f "molecule/default/requirements.yml"; then
90+ cp molecule/default/requirements.yml molecule/github/requirements.yml
91+ fi
92+
7993 # Add prepare playbook if exists
8094 if test -f "molecule/default/prepare.yml"; then
8195 yq e --inplace '.provisioner.playbooks += {"prepare":"../default/prepare.yml"}' molecule/github/molecule.yml
@@ -92,8 +106,10 @@ jobs:
92106 run : pip3 install -r molecule/requirements.txt
93107
94108 - name : Install Ansible Role Requirements
95- run : ansible-galaxy install -r requirements.yml
96- continue-on-error : true
109+ run : |
110+ if test -f "requirements.yml"; then
111+ ansible-galaxy install -r requirements.yml
112+ fi
97113
98114 - name : Disable AppArmor (MySQL)
99115 run : |
You can’t perform that action at this time.
0 commit comments