Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions .github/workflows/build-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ on:
jobs:
coordinator:
uses: ./.github/workflows/coordinator-build-and-publish.yml
if: ${{ always() && (inputs.coordinator_changed == 'true' || inputs.coordinator_image_tagged != 'true') }}
if: ${{ always() && (inputs.coordinator_changed == 'true' || (inputs.push_image && inputs.coordinator_image_tagged != 'true')) }}
with:
commit_tag: ${{ inputs.commit_tag }}
develop_tag: ${{ inputs.develop_tag }}
Expand All @@ -76,8 +76,6 @@ jobs:
native_yield_automation_service:
uses: ./.github/workflows/native-yield-automation-service-build-and-publish.yml
if: ${{ inputs.native_yield_automation_service_changed == 'true' }}
# Uncomment below later when E2E test cases include native yield functionality.
# if: ${{ always() && (inputs.native_yield_automation_service_changed == 'true' || inputs.native_yield_automation_service_image_tagged != 'true') }}
with:
commit_tag: ${{ inputs.commit_tag }}
develop_tag: ${{ inputs.develop_tag }}
Expand All @@ -87,7 +85,7 @@ jobs:

prover:
uses: ./.github/workflows/prover-build-and-publish.yml
if: ${{ always() && (inputs.prover_changed == 'true' || inputs.prover_image_tagged != 'true') }}
if: ${{ always() && (inputs.prover_changed == 'true' || (inputs.push_image && inputs.prover_image_tagged != 'true')) }}
with:
commit_tag: ${{ inputs.commit_tag }}
develop_tag: ${{ inputs.develop_tag }}
Expand All @@ -97,7 +95,7 @@ jobs:

postman:
uses: ./.github/workflows/postman-build-and-publish.yml
if: ${{ always() && (inputs.postman_changed == 'true' || inputs.postman_image_tagged != 'true') }}
if: ${{ always() && (inputs.postman_changed == 'true' || (inputs.push_image && inputs.postman_image_tagged != 'true')) }}
with:
commit_tag: ${{ inputs.commit_tag }}
develop_tag: ${{ inputs.develop_tag }}
Expand All @@ -107,7 +105,7 @@ jobs:

transaction_exclusion_api:
uses: ./.github/workflows/transaction-exclusion-api-build-and-publish.yml
if: ${{ always() && (inputs.transaction_exclusion_api_changed == 'true' || inputs.transaction_exclusion_api_image_tagged != 'true') }}
if: ${{ always() && (inputs.transaction_exclusion_api_changed == 'true' || (inputs.push_image && inputs.transaction_exclusion_api_image_tagged != 'true')) }}
with:
commit_tag: ${{ inputs.commit_tag }}
develop_tag: ${{ inputs.develop_tag }}
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/reuse-check-images-tags-and-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ on:
develop_tag:
value: ${{ jobs.check_image_tags_exist.outputs.develop_tag }}
image_tagged_coordinator:
value: ${{ jobs.image_tag_push.outputs.image_tagged_coordinator }}
value: ${{ jobs.image_tag_push.outputs.image_tagged_coordinator || 'false' }}
image_tagged_prover:
value: ${{ jobs.image_tag_push.outputs.image_tagged_prover }}
value: ${{ jobs.image_tag_push.outputs.image_tagged_prover || 'false' }}
image_tagged_postman:
value: ${{ jobs.image_tag_push.outputs.image_tagged_postman }}
value: ${{ jobs.image_tag_push.outputs.image_tagged_postman || 'false' }}
image_tagged_native_yield_automation_service:
value: ${{ jobs.image_tag_push.outputs.image_tagged_native_yield_automation_service }}
value: ${{ jobs.image_tag_push.outputs.image_tagged_native_yield_automation_service || 'false' }}
image_tagged_transaction_exclusion_api:
value: ${{ jobs.image_tag_push.outputs.image_tagged_transaction_exclusion_api }}
value: ${{ jobs.image_tag_push.outputs.image_tagged_transaction_exclusion_api || 'false' }}
secrets:
DOCKERHUB_USERNAME:
required: false
Expand Down Expand Up @@ -94,39 +94,39 @@ jobs:

- name: Check image tags exist for coordinator
uses: ./.github/actions/check-image-tags-exist
if: ${{ inputs.coordinator_changed == 'false' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.coordinator_changed == 'false' }}
id: check_image_tags_exist_coordinator
with:
last_commit_tag: ${{ steps.compute-version-tags.outputs.LAST_COMMIT_TAG }}
image_name: consensys/linea-coordinator

- name: Check image tags exist for postman
uses: ./.github/actions/check-image-tags-exist
if: ${{ inputs.postman_changed == 'false' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.postman_changed == 'false' }}
id: check_image_tags_exist_postman
with:
last_commit_tag: ${{ steps.compute-version-tags.outputs.LAST_COMMIT_TAG }}
image_name: consensys/linea-postman

- name: Check image tags exist for native-yield-automation-service
uses: ./.github/actions/check-image-tags-exist
if: ${{ inputs.native_yield_automation_service_changed == 'false' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.native_yield_automation_service_changed == 'false' }}
id: check_image_tags_exist_native_yield_automation_service
with:
last_commit_tag: ${{ steps.compute-version-tags.outputs.LAST_COMMIT_TAG }}
image_name: consensys/linea-native-yield-automation-service

- name: Check image tags exist for prover
uses: ./.github/actions/check-image-tags-exist
if: ${{ inputs.prover_changed == 'false' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.prover_changed == 'false' }}
id: check_image_tags_exist_prover
with:
last_commit_tag: ${{ steps.compute-version-tags.outputs.LAST_COMMIT_TAG }}
image_name: consensys/linea-prover

- name: Check image tags exist for transaction-exclusion-api
uses: ./.github/actions/check-image-tags-exist
if: ${{ inputs.transaction_exclusion_api_changed == 'false' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.transaction_exclusion_api_changed == 'false' }}
id: check_image_tags_exist_transaction_exclusion_api
with:
last_commit_tag: ${{ steps.compute-version-tags.outputs.LAST_COMMIT_TAG }}
Expand Down
41 changes: 30 additions & 11 deletions .github/workflows/reuse-run-e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,6 @@ jobs:
# We can only use conditionals, and not path filters to 'successfully' skip a required job - https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks
if: ${{ inputs.has-changes-requiring-e2e-testing == 'true' }}
env:
COORDINATOR_TAG: ${{ inputs.commit_tag }}
POSTMAN_TAG: ${{ inputs.commit_tag }}
PROVER_TAG: ${{ inputs.commit_tag }}
TRANSACTION_EXCLUSION_API_TAG: ${{ inputs.commit_tag }}
BESU_PACKAGE_TAG: ${{ inputs.linea_besu_package_tag }}
EXPECTED_TRACES_API_VERSION: ${{ inputs.expected_traces_api_version }}
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
Expand Down Expand Up @@ -121,14 +117,37 @@ jobs:
with:
pattern: linea-*

- name: Load Docker images
run: |
pwd && ls -la && echo "GITHUB_WORKSPACE=$GITHUB_WORKSPACE" &&
gunzip -c $GITHUB_WORKSPACE/linea-coordinator/linea-coordinator-docker-image.tar.gz | docker load &&
gunzip -c $GITHUB_WORKSPACE/linea-postman/linea-postman-docker-image.tar.gz | docker load &&
gunzip -c $GITHUB_WORKSPACE/linea-prover/linea-prover-docker-image.tar.gz | docker load &&
gunzip -c $GITHUB_WORKSPACE/linea-transaction-exclusion-api/linea-transaction-exclusion-api-docker-image.tar.gz | docker load
- name: Load Docker images from artifacts or pull develop for unchanged services
uses: nick-fields/retry@ce71cc2ab81d554ebbe88c79ab5975992d79ba08 #v3.0.2
with:
max_attempts: 10
retry_on: error
retry_wait_seconds: 30
timeout_minutes: 10
command: |
set -eo pipefail
for service in coordinator postman prover transaction-exclusion-api; do
artifact_path="$GITHUB_WORKSPACE/linea-${service}/linea-${service}-docker-image.tar.gz"
if [ -f "$artifact_path" ]; then
echo "Loading ${service} from build artifact..."
gunzip -c "$artifact_path" | docker load
else
echo "No artifact found for ${service}, pulling develop tag from registry..."
docker pull "consensys/linea-${service}:develop"
fi
done
- name: Set Docker image tags
shell: bash
run: |
for service in coordinator postman prover transaction-exclusion-api; do
artifact_path="$GITHUB_WORKSPACE/linea-${service}/linea-${service}-docker-image.tar.gz"
env_var="$(echo "${service}" | tr '[:lower:]-' '[:upper:]_')_TAG"
if [ -f "$artifact_path" ]; then
echo "${env_var}=${{ inputs.commit_tag }}" >> "$GITHUB_ENV"
else
echo "${env_var}=develop" >> "$GITHUB_ENV"
fi
done
- name: Load linea-besu-package Docker image
if: ${{ inputs.linea_besu_package_tag != '' }}
run: |
Expand Down
Loading