-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into chore/498-v5-techdebt-cleanup
- Loading branch information
Showing
99 changed files
with
2,377 additions
and
740 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: 'Compute Docker Images Hash' | ||
description: 'Compute Docker Images Hash for Cache Key' | ||
|
||
outputs: | ||
docker_images_hash: | ||
description: 'Docker Images Hash' | ||
value: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES_HASH }} | ||
docker_images_trimmed: | ||
description: 'Trimmed List of Docker Images' | ||
value: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES_TRIMMED }} | ||
|
||
runs: | ||
using: 'composite' | ||
steps: | ||
- name: Compute docker images hash | ||
id: compute-docker-images-hash | ||
shell: bash | ||
run: | | ||
docker_images_traces_v1=$(docker compose -f docker/compose.yml -f docker/compose-local-dev.overrides.yml --profile l1 --profile l2 config 2>/dev/null | grep "image:" | awk '{print $2}') | ||
docker_images_traces_v2=$(docker compose -f docker/compose.yml -f docker/compose-local-dev-traces-v2.overrides.yml --profile l1 --profile l2 config 2>/dev/null | grep "image:" | awk '{print $2}') | ||
docker_images=$(echo "$docker_images_traces_v1 $docker_images_traces_v2") | ||
docker_images_unique=$(echo $docker_images | xargs -n1 | sort -u) | ||
docker_images_trimmed=$(echo $docker_images_unique | xargs -n1 | grep -Ev "linea-postman|linea-coordinator|linea-transaction-exclusion-api|linea-traces-api-facade|linea-prover" | xargs) | ||
echo DOCKER_IMAGES=$(echo $docker_images) >> $GITHUB_OUTPUT | ||
echo DOCKER_IMAGES_UNIQUE=$(echo $docker_images_unique) >> $GITHUB_OUTPUT | ||
echo DOCKER_IMAGES_TRIMMED=$(echo $docker_images_trimmed) >> $GITHUB_OUTPUT | ||
echo DOCKER_IMAGES_HASH=$(echo -n $docker_images_trimmed | sha256sum | awk '{print $1}') >> $GITHUB_OUTPUT | ||
- name: Show docker images hash | ||
shell: bash | ||
id: show-docker-images-hash | ||
run: | | ||
echo "DOCKER_IMAGES: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES }}" | ||
echo "DOCKER_IMAGES_UNIQUE: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES_UNIQUE }}" | ||
echo "DOCKER_IMAGES_TRIMMED: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES_TRIMMED }}" | ||
echo "DOCKER_IMAGES_HASH: ${{ steps.compute-docker-images-hash.outputs.DOCKER_IMAGES_HASH }}" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: 'Restore Cached Docker Images' | ||
description: 'Restore Cached Docker Images' | ||
|
||
runs: | ||
using: 'composite' | ||
steps: | ||
- name: Compute docker images hash | ||
id: compute-docker-images-hash | ||
uses: ./.github/actions/compute-docker-images-hash | ||
- name: Create cached docker images folder | ||
shell: bash | ||
run: | | ||
mkdir -p ~/docker-images-cached | ||
- name: Cache common docker images | ||
id: cache-common-docker-images | ||
continue-on-error: true | ||
uses: actions/cache/restore@v4.2.0 | ||
with: | ||
path: ~/docker-images-cached | ||
key: docker-images-cache-${{ steps.compute-docker-images-hash.outputs.docker_images_hash }} | ||
- name: Load docker images | ||
shell: bash | ||
if: steps.cache-common-docker-images.outputs.cache-hit == 'true' | ||
run: | | ||
docker load -i ~/docker-images-cached/docker-images.tar |
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.