Skip to content

Commit

Permalink
Merge branch 'main' into rebase-devnet-5
Browse files Browse the repository at this point in the history
  • Loading branch information
SebastianElvis committed Nov 14, 2024
2 parents 8ee2c85 + dd4009d commit d10dd40
Show file tree
Hide file tree
Showing 416 changed files with 32,007 additions and 38,996 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/backport.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Adapted from https://github.com/marketplace/actions/backporting
#
# Usage:
# - Let's say you want to backport a pull request on a branch named `production`.
# - Then label it with `backport production`.
# - That's it! When the pull request gets merged, it will be backported to
# the `production` branch. If the pull request cannot be backported, a comment
# explaining why will automatically be posted.
#
# Note: multiple backport labels can be added. For example, if a pull request
# has the labels `backport staging` and `backport production` it will be
# backported to both branches: `staging` and `production`.
name: Backport
on:
pull_request_target:
types:
- closed
- labeled

jobs:
backport:
name: Backport
runs-on: ubuntu-latest
# Only react to merged PRs for security reasons.
# See https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request_target.
if: >
github.event.pull_request.merged
&& (
github.event.action == 'closed'
|| (
github.event.action == 'labeled'
&& contains(github.event.label.name, 'backport')
)
)
steps:
- uses: tibdex/backport@v2
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
11 changes: 11 additions & 0 deletions .github/workflows/changelog-reminder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Changelog Reminder
on:
pull_request:
types: [assigned, opened, synchronize, reopened, labeled, unlabeled]
branches:
- main

jobs:
changelog_reminder:
uses: babylonlabs-io/.github/.github/workflows/[email protected]
secrets: inherit
100 changes: 19 additions & 81 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,17 @@ concurrency:

jobs:
lint_test:
uses: babylonlabs-io/.github/.github/workflows/reusable_go_lint_test.yml@v0.5.0
uses: babylonlabs-io/.github/.github/workflows/reusable_go_lint_test.yml@v0.7.0
secrets: inherit
with:
go-version: '1.23'
go-lint-version: 'v1.60.2'
run-unit-tests: true
run-integration-tests: false
run-lint: true

docker_pipeline:
uses: babylonlabs-io/.github/.github/workflows/reusable_docker_pipeline.yml@v0.5.0
uses: babylonlabs-io/.github/.github/workflows/reusable_docker_pipeline.yml@v0.7.0
secrets: inherit
with:
publish: false
Expand Down Expand Up @@ -47,29 +49,6 @@ jobs:
name: babylond-${{ github.sha }} # so it renovates at every new sha
path: /tmp/docker-babylond.tar.gz

e2e-docker-build-babylon-before-upgrade:
runs-on: ubuntu-22.04
steps:
# - name: Artifact babylond-before-upgrade exists # TODO: check why it doesn't work to load from older workflow runs .-.
# uses: xSAVIKx/artifact-exists-action@v0
# id: check-babylond-before-upgrade
# with:
# name: babylond-before-upgrade
- name: Checkout repository
uses: actions/checkout@v4
- name: Build docker babylond-before-upgrade
run: |
make -C contrib/images babylond-before-upgrade
- name: Docker save babylond-before-upgrade
run: |
docker save -o /tmp/docker-babylond-before-upgrade.tar.gz babylonlabs-io/babylond-before-upgrade:latest
- name: Upload babylond-before-upgrade artifact
uses: actions/upload-artifact@v4
with:
name: babylond-before-upgrade
path: /tmp/docker-babylond-before-upgrade.tar.gz
# retention-days: 90 active this back if artifact-exists-action works

e2e-docker-build-e2e-init-chain:
runs-on: ubuntu-22.04
steps:
Expand Down Expand Up @@ -127,7 +106,7 @@ jobs:
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
go-version: 1.23
- name: Run e2e TestIBCTranferTestSuite
run: |
make test-e2e-cache-ibc-transfer
Expand All @@ -149,39 +128,12 @@ jobs:
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
go-version: 1.23
- name: Run e2e TestBTCTimestampingTestSuite
run: |
make test-e2e-cache-btc-timestamping
e2e-run-btc-timestamping-phase-2-hermes:
needs: [e2e-docker-build-babylon]
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Download babylon artifact
uses: actions/download-artifact@v4
with:
name: babylond-${{ github.sha }}
path: /tmp
- name: Docker load babylond
run: |
docker load < /tmp/docker-babylond.tar.gz
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
- name: Run e2e TestBTCTimestampingPhase2HermesTestSuite
run: |
make test-e2e-cache-btc-timestamping-phase-2-hermes
e2e-run-btc-timestamping-phase-2-rly:
e2e-run-btc-staking:
needs: [e2e-docker-build-babylon]
runs-on: ubuntu-22.04
steps:
Expand All @@ -195,20 +147,15 @@ jobs:
- name: Docker load babylond
run: |
docker load < /tmp/docker-babylond.tar.gz
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
- name: Run e2e TestBTCTimestampingPhase2RlyTestSuite
go-version: 1.23
- name: Run e2e TestBTCStakingTestSuite
run: |
make test-e2e-cache-btc-timestamping-phase-2-rly
make test-e2e-cache-btc-staking
e2e-run-btc-staking:
e2e-run-btc-staking-pre-approval:
needs: [e2e-docker-build-babylon]
runs-on: ubuntu-22.04
steps:
Expand All @@ -225,13 +172,13 @@ jobs:
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
- name: Run e2e TestBTCStakingTestSuite
go-version: 1.23
- name: Run e2e TestBTCStakingPreApprovalTestSuite
run: |
make test-e2e-cache-btc-staking
make test-e2e-cache-btc-staking-pre-approval
e2e-run-upgrade-signet:
needs: [e2e-docker-build-babylon, e2e-docker-build-babylon-before-upgrade, e2e-docker-build-e2e-init-chain]
e2e-run-upgrade-v1:
needs: [e2e-docker-build-babylon, e2e-docker-build-e2e-init-chain]
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
Expand All @@ -241,11 +188,6 @@ jobs:
with:
name: babylond-${{ github.sha }}
path: /tmp
- name: Download babylond-before-upgrade artifact
uses: actions/download-artifact@v4
with:
name: babylond-before-upgrade
path: /tmp
- name: Download init-chain artifact
uses: actions/download-artifact@v4
with:
Expand All @@ -255,21 +197,17 @@ jobs:
run: |
docker load < /tmp/docker-babylond.tar.gz
- name: Docker load babylond-before-upgrade
run: |
docker load < /tmp/docker-babylond-before-upgrade.tar.gz
- name: Docker load init chain
run: |
docker load < /tmp/docker-init-chain.tar.gz
- name: Cache Go
uses: actions/setup-go@v5
with:
go-version: 1.21
- name: Run e2e TestSoftwareUpgradeSignetLaunchTestSuite
go-version: 1.23
- name: Run e2e TestSoftwareUpgradeV1TestnetTestSuite
run: |
sudo make test-e2e-cache-upgrade-signet
sudo make test-e2e-cache-upgrade-v1
e2e-run-bcd-consumer-integration-test:
needs: [e2e-docker-build-babylon, e2e-docker-build-ibcsim-bcd]
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: goreleaser

on:
release:
types: [published]

permissions:
contents: write

jobs:
release:
uses: babylonlabs-io/.github/.github/workflows/[email protected]
secrets: inherit
6 changes: 4 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,17 @@ on:

jobs:
lint_test:
uses: babylonlabs-io/.github/.github/workflows/reusable_go_lint_test.yml@v0.5.0
uses: babylonlabs-io/.github/.github/workflows/reusable_go_lint_test.yml@v0.7.0
secrets: inherit
with:
go-version: '1.23'
go-lint-version: 'v1.60.2'
run-unit-tests: true
run-integration-tests: false
run-lint: true

docker_pipeline:
uses: babylonlabs-io/.github/.github/workflows/reusable_docker_pipeline.yml@v0.5.0
uses: babylonlabs-io/.github/.github/workflows/reusable_docker_pipeline.yml@v0.7.0
needs: ["lint_test"]
secrets: inherit
with:
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -214,4 +214,5 @@ docs/diagrams/plantuml.jar
.testnets/
.testnet/
mytestnet/
output/
output/
dist/
57 changes: 57 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
version: 2
project_name: babylon

builds:
- id: babylond-linux-amd64
main: ./cmd/babylond/main.go
binary: babylond
goos:
- linux
goarch:
- amd64
env:
- GO111MODULE=on
flags:
- -mod=readonly
- -trimpath
ldflags:
- -X github.com/cosmos/cosmos-sdk/version.Name=babylon
- -X github.com/cosmos/cosmos-sdk/version.AppName=babylond
- -X github.com/cosmos/cosmos-sdk/version.Version={{ .Version }}
- -X github.com/cosmos/cosmos-sdk/version.Commit={{ .Commit }}
- -X github.com/cosmos/cosmos-sdk/version.BuildTags=netgo,ledger
- -w -s
tags:
- netgo
- ledger

archives:
- id: zipped
builds:
- babylond-linux-amd64
name_template: "{{.ProjectName}}-{{ .Version }}-{{ .Os }}-{{ .Arch }}"
format: tar.gz
files:
- none*
- id: binaries
builds:
- babylond-linux-amd64
name_template: "{{.ProjectName}}-{{ .Version }}-{{ .Os }}-{{ .Arch }}"
format: binary
files:
- none*

checksum:
name_template: "{{ .ProjectName }}_{{ .Version }}_checksums.txt"
algorithm: sha256

release:
github:
owner: babylonlabs-io
name: babylon

# Docs: https://goreleaser.com/customization/changelog/
changelog:
disable: true

dist: dist
Loading

0 comments on commit d10dd40

Please sign in to comment.