diff --git a/.github/workflows/cache.yml b/.github/workflows/cache.yml index c74d2e2..83b20cc 100644 --- a/.github/workflows/cache.yml +++ b/.github/workflows/cache.yml @@ -23,6 +23,7 @@ jobs: - name: Cache Ansible uses: actions/cache@13aacd865c20de90d75de3b17ebe84f7a17d57d2 # 4.0 + id: cache-ansible with: path: ~/.ansible/collections key: ansible-${{ hashFiles('collections/requirements.txt') }} @@ -39,6 +40,9 @@ jobs: python3 -m pip install -r requirements.txt echo "::endgroup::" + - name: Install ansible dependencies + if: steps.cache-ansible.outputs.cache-hit != 'true' # only run if false since this is just a cache step + run: | echo "::group::Install Ansible role requirements from collections/requirements.yml" ansible-galaxy install -r collections/requirements.yml echo "::endgroup::"