Skip to content

Commit

Permalink
Revert "Feature: Merge mangata-node repository code (#411)"
Browse files Browse the repository at this point in the history
This reverts commit ed4a6cd.
  • Loading branch information
vanderian authored Jan 22, 2025
1 parent ed4a6cd commit add7669
Show file tree
Hide file tree
Showing 205 changed files with 153 additions and 92,931 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/branch-frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ concurrency:
jobs:
init:
name: Set global version
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
outputs:
GLOBAL_VERSION: ${{ steps.set_vars.outputs.GLOBAL_VERSION }}
steps:
Expand Down
80 changes: 5 additions & 75 deletions .github/workflows/branch-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,13 @@ name: main branch workflow

on:
push:
branches: [main]
branches: [main, feat/add-main-branch-ci-pipeline-MGX-834]

permissions:
contents: write
id-token: write
deployments: write
checks: write
security-events: write

# The following concurrency group queus in-progress jobs
concurrency:
Expand All @@ -19,94 +18,25 @@ concurrency:
jobs:
init:
name: Set global version
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
outputs:
GLOBAL_VERSION: ${{ steps.set_vars.outputs.GLOBAL_VERSION }}
GIT_BRANCH: ${{ steps.set_vars.outputs.GIT_BRANCH }}
GIT_BRANCH_UNFORMATTED: ${{ steps.branch-name.outputs.current_branch }}
steps:
- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@v8
- name: Set global version
id: set_vars
run: |
echo "GLOBAL_VERSION=${{ github.sha }}" >> $GITHUB_OUTPUT
echo "GIT_BRANCH=${{ steps.branch-name.outputs.current_branch }}" | sed "s@/@-@g" >> $GITHUB_OUTPUT
echo "IMAGE_TAG=${{ github.sha }}" >> $GITHUB_STEP_SUMMARY
run: echo "GLOBAL_VERSION=${{ github.sha }}" >> $GITHUB_OUTPUT

build-and-test:
needs: [init]
name: Build AVS services
name: Build
uses: ./.github/workflows/reusable-build-and-test.yml
secrets: inherit
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}

build-and-test-gasp-node:
needs: [init]
name: Build gasp-node
uses: ./.github/workflows/reusable-gasp-node-build-and-test.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
id-token: write
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}
branch: ${{ needs.init.outputs.GIT_BRANCH }}

gasp-node-unit-tests-and-coverage:
name: '[gasp-node] Run unit tests and coverage'
needs: [init]
uses: ./.github/workflows/reusable-gasp-node-unit-tests-and-coverage.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
id-token: write
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}
branch: ${{ needs.init.outputs.GIT_BRANCH }}

gasp-node-generate-types:
name: '[gasp-node] Generate types'
needs: [init, build-and-test-gasp-node]
uses: ./.github/workflows/reusable-gasp-node-generate-types.yml
secrets: inherit
with:
branch: ${{ needs.init.outputs.GIT_BRANCH_UNFORMATTED }}
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}

run-e2e-test:
name: Run e2e tests
needs: [init, build-and-test]
uses: ./.github/workflows/reusable-e2e-tests.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
with:
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}

run-e2e-test-gasp-node:
name: '[gasp-node] Run e2e tests'
needs: [init, build-and-test-gasp-node, gasp-node-generate-types]
uses: ./.github/workflows/reusable-gasp-node-e2e-tests.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
with:
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}

deploy-dev:
name: Deploy `dev` environment
needs: [init, build-and-test, build-and-test-gasp-node, gasp-node-unit-tests-and-coverage]
needs: [init, build-and-test]
uses: ./.github/workflows/reusable-deploy.yml
secrets: inherit
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/deploy-rollup-holesky.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ permissions:
jobs:
init:
name: Set global version
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
outputs:
GLOBAL_VERSION: ${{ steps.set_vars.outputs.GLOBAL_VERSION }}
steps:
Expand All @@ -29,7 +29,7 @@ jobs:

deploy-rollup-holesky:
needs: [init, build-and-test]
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: jkroepke/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/faucet-deploy-app-engine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ env:

jobs:
build-and-deploy:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- name: Checkout repository
Expand Down
86 changes: 15 additions & 71 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ permissions:
id-token: write
deployments: write
checks: write
security-events: write

# The following concurrency group cancels in-progress jobs or runs on pull_request events only
# https://docs.github.com/en/actions/using-jobs/using-concurrency#example-using-a-fallback-value
Expand All @@ -20,66 +19,35 @@ jobs:
init:
name: Set global version
if: github.event.action != 'unlabeled' && github.event.action != 'closed'
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
outputs:
GLOBAL_VERSION: ${{ steps.set_vars.outputs.GLOBAL_VERSION }}
GIT_BRANCH: ${{ steps.set_vars.outputs.GIT_BRANCH }}
GIT_BRANCH_UNFORMATTED: ${{ steps.branch-name.outputs.current_branch }}
steps:
- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@v8
- name: Set global version
id: set_vars
run: |
echo "GLOBAL_VERSION=${{ github.sha }}" >> $GITHUB_OUTPUT
echo "GIT_BRANCH=${{ steps.branch-name.outputs.current_branch }}" | sed "s@/@-@g" >> $GITHUB_OUTPUT
echo "IMAGE_TAG=${{ github.sha }}" >> $GITHUB_STEP_SUMMARY
echo "IMAGE TAG=${{ github.sha }}" >> $GITHUB_STEP_SUMMARY
build-and-test:
needs: [init]
name: '[AVS services] Build'
name: Build
uses: ./.github/workflows/reusable-build-and-test.yml
secrets: inherit
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}

build-and-test-gasp-node:
needs: [init]
name: '[gasp-node] Build'
uses: ./.github/workflows/reusable-gasp-node-build-and-test.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
id-token: write
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}
branch: ${{ needs.init.outputs.GIT_BRANCH }}

gasp-node-unit-tests-and-coverage:
name: '[gasp-node] Run unit tests and coverage'
needs: [init]
uses: ./.github/workflows/reusable-gasp-node-unit-tests-and-coverage.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
id-token: write
with:
version: ${{ needs.init.outputs.GLOBAL_VERSION }}
branch: ${{ needs.init.outputs.GIT_BRANCH }}

gasp-node-generate-types:
name: '[gasp-node] Generate types'
needs: [init, build-and-test-gasp-node]
uses: ./.github/workflows/reusable-gasp-node-generate-types.yml
deploy-fungible:
name: Deploy fungible environment
if: |
(github.event_name == 'pull_request' && github.event.action == 'labeled' && github.event.label.name == ':rocket: deploy_fungible') ||
(github.event_name == 'pull_request' && github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, ':rocket: deploy_fungible'))
needs: [init, build-and-test]
uses: ./.github/workflows/reusable-deploy.yml
secrets: inherit
with:
branch: ${{ needs.init.outputs.GIT_BRANCH_UNFORMATTED }}
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}
env: fungible
version: ${{ needs.init.outputs.GLOBAL_VERSION }}

run-e2e-test:
name: Run e2e tests
Expand All @@ -92,45 +60,21 @@ jobs:
checks: write
with:
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}

run-e2e-test-gasp-node:
name: '[gasp-node] Run e2e tests'
needs: [init, build-and-test-gasp-node, gasp-node-generate-types]
uses: ./.github/workflows/reusable-gasp-node-e2e-tests.yml
secrets: inherit
permissions:
contents: read
actions: read
checks: write
with:
globalVersion: ${{ needs.init.outputs.GLOBAL_VERSION }}

deploy-fungible:
name: Deploy fungible environment
if: |
(github.event_name == 'pull_request' && github.event.action == 'labeled' && github.event.label.name == ':rocket: deploy_fungible') ||
(github.event_name == 'pull_request' && github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, ':rocket: deploy_fungible'))
needs: [init, build-and-test, build-and-test-gasp-node, gasp-node-unit-tests-and-coverage]
uses: ./.github/workflows/reusable-deploy.yml
secrets: inherit
with:
env: fungible
version: ${{ needs.init.outputs.GLOBAL_VERSION }}

clean-up-fungible:
name: Delete fungible environment
if: |
(github.event_name == 'pull_request' && github.event.action == 'unlabeled' && github.event.label.name == ':rocket: deploy_fungible') ||
(github.event_name == 'pull_request' && github.event.action == 'closed' && contains(github.event.pull_request.labels.*.name, ':rocket: deploy_fungible'))
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: google-github-actions/auth@v2
with:
workload_identity_provider: ${{ secrets.GCP_WORKLOAD_IDENTITY_PROVIDER }}
service_account: ${{ secrets.GCP_SERVICE_ACCOUNT }}
- name: Set up GKE credentials
uses: google-github-actions/get-gke-credentials@v2.3.0
uses: google-github-actions/get-gke-credentials@v0.8.2
with:
cluster_name: mangata-dev-alpha
location: europe-west1
Expand All @@ -140,7 +84,7 @@ jobs:

- name: Delete GitHub Deployment environment
if: always()
uses: bobheadxi/deployments@v1.5.0
uses: bobheadxi/deployments@v1.4.0
with:
step: deactivate-env
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
Loading

0 comments on commit add7669

Please sign in to comment.