Cache images slightly differently (#165)

This commit is contained in:
Marco Munizaga
2023-04-11 11:29:32 -07:00
committed by GitHub
parent 1bc8283cd6
commit 23fdcef9be
62 changed files with 304 additions and 120 deletions

View File

@@ -34,6 +34,12 @@ runs:
echo "AWS_REGION=${{ inputs.aws-region }}" >> $GITHUB_ENV
shell: bash
- name: Configure AWS credentials for S3 build cache
if: inputs.s3-access-key-id != '' && inputs.s3-secret-access-key != ''
run: |
echo "PUSH_CACHE=true" >> $GITHUB_ENV
shell: bash
- name: Configure AWS credentials for S3 build cache
if: inputs.s3-access-key-id != '' && inputs.s3-secret-access-key != ''
uses: aws-actions/configure-aws-credentials@v1
@@ -63,9 +69,15 @@ runs:
run: npm ci
shell: bash
- name: Build images
- name: Load cache and build
working-directory: ${{ steps.find-workdir.outputs.WORK_DIR }}
run: make
run: npm run cache -- load
shell: bash
- name: Push the image cache
if: env.PUSH_CACHE == 'true'
working-directory: ${{ steps.find-workdir.outputs.WORK_DIR }}
run: npm run cache -- push
shell: bash
- name: Run the test