From d194fb22b7a5f73b143e65ab6f774ffa0f899976 Mon Sep 17 00:00:00 2001 From: Hayato Date: Wed, 30 Oct 2024 21:41:48 +0900 Subject: [PATCH] Stop using cache mechanism before ansible-play --- .github/workflows/develop_branch.yml | 30 +++++-------------- .github/workflows/main_branch.yml | 44 +++++++++------------------- 2 files changed, 21 insertions(+), 53 deletions(-) diff --git a/.github/workflows/develop_branch.yml b/.github/workflows/develop_branch.yml index 0badedd..fb9e347 100644 --- a/.github/workflows/develop_branch.yml +++ b/.github/workflows/develop_branch.yml @@ -28,14 +28,6 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Restore Caches - uses: actions/cache/restore@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles - - name: Prepare environments (ansible-galaxy install role) run: | ansible-galaxy role install -r requirements.yml --ignore-errors @@ -48,14 +40,6 @@ jobs: run: | ansible-lint - - name: Save Caches - uses: actions/cache/save@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles - Duplicate_Check: runs-on: ubuntu-latest steps: @@ -97,13 +81,13 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Restore Caches - uses: actions/cache/restore@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles + - name: Prepare environments (ansible-galaxy install role) + run: | + ansible-galaxy role install -r requirements.yml --ignore-errors + + - name: Prepare environments (ansible-galaxy install collection) + run: | + ansible-galaxy collection install -r requirements.yml --ignore-errors - name: "ansible-playbook -C" env: diff --git a/.github/workflows/main_branch.yml b/.github/workflows/main_branch.yml index f13ed3f..240f68b 100644 --- a/.github/workflows/main_branch.yml +++ b/.github/workflows/main_branch.yml @@ -27,14 +27,6 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Restore Caches - uses: actions/cache/restore@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles - - name: Prepare environments (ansible-galaxy install role) run: | ansible-galaxy role install -r requirements.yml --ignore-errors @@ -47,14 +39,6 @@ jobs: run: | ansible-lint - - name: Save Caches - uses: actions/cache/save@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles - Duplicate_Check: runs-on: ubuntu-latest steps: @@ -99,13 +83,13 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Restore Caches - uses: actions/cache/restore@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles + - name: Prepare environments (ansible-galaxy install role) + run: | + ansible-galaxy role install -r requirements.yml --ignore-errors + + - name: Prepare environments (ansible-galaxy install collection) + run: | + ansible-galaxy collection install -r requirements.yml --ignore-errors - name: "ansible-playbook -C" env: @@ -144,13 +128,13 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Restore Caches - uses: actions/cache/restore@v4 - with: - path: | - /github/home/.cache/ - /github/home/.ansible/ - key: cache-ansible-roles + - name: Prepare environments (ansible-galaxy install role) + run: | + ansible-galaxy role install -r requirements.yml --ignore-errors + + - name: Prepare environments (ansible-galaxy install collection) + run: | + ansible-galaxy collection install -r requirements.yml --ignore-errors - name: "Run ansible-playbook" env: