Skip to content

Commit

Permalink
Merge pull request #203 from covalenthq/develop
Browse files Browse the repository at this point in the history
Upgrade `bsp-geth` with workflows and dockerfiles to golang 1.22.2
  • Loading branch information
noslav authored Jun 12, 2024
2 parents fd1af89 + c17871a commit 52fdf98
Show file tree
Hide file tree
Showing 9 changed files with 47 additions and 28 deletions.
11 changes: 9 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,12 @@ updates:
target-branch: "develop"
reviewers:
- "noslav"
- "sudeepdino008"

- "rogarcia"
- package-ecosystem: "docker"
directory: "/"
schedule:
interval: "weekly"
target-branch: "develop"
reviewers:
- "noslav"
- "rogarcia"
6 changes: 5 additions & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,16 @@ jobs:
audit:
runs-on: ubuntu-20.04
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.6.0
with:
access_token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.21.4
go-version: 1.22.2

- name: Checkout code
uses: actions/checkout@v2
Expand Down
40 changes: 22 additions & 18 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,34 @@ name: docker-image-ci
on:
push:
branches:
- "main"
- "main"
pull_request:
branches:
- "main"
- "develop"
branches:
- "main"
- "develop"

jobs:
push-image:
runs-on: ubuntu-latest
steps:
- name: Login to GitHub Container Registry
if: ${{ !env.ACT }}
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ secrets.CR_USER }}
password: ${{ secrets.CR_PAT }}
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.6.0
with:
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Login to GitHub Container Registry
if: ${{ !env.ACT }}
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ secrets.CR_USER }}
password: ${{ secrets.CR_PAT }}

- uses: actions/checkout@v2
- name: Build & Publish the Docker image
if: ${{ !env.ACT }}
run: |
docker build . --file Dockerfile --tag ghcr.io/covalenthq/bsp-geth:latest
docker push ghcr.io/covalenthq/bsp-geth:latest
- uses: actions/checkout@v2
- name: Build & Publish the Docker image
if: ${{ !env.ACT }}
run: |
docker build . --file Dockerfile --tag ghcr.io/covalenthq/bsp-geth:latest
docker push ghcr.io/covalenthq/bsp-geth:latest
# - name: Start containers
# run: docker-compose -f "docker-compose.yml" up --build --remove-orphans --force-recreate --exit-code-from agent
Expand All @@ -39,4 +43,4 @@ jobs:

# - name: Stop containers
# if: always()
# run: docker-compose -f "docker-compose.yml" down
# run: docker-compose -f "docker-compose.yml" down
4 changes: 4 additions & 0 deletions .github/workflows/gcr-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.6.0
with:
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Login to GCR
uses: docker/login-action@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.21.4
go-version: 1.22.2
- name: Run tests
run: go test -short ./...
env:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
- name: Set up Go 1.19
- name: Set up Go 1.22.2
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: 1.22.2
id: go
- run: go version

Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ARG USER=$USER


# Build Geth in a stock Go builder container
FROM golang:1.21-alpine as builder
FROM golang:1.22-alpine as builder

RUN apk add --no-cache gcc musl-dev linux-headers git

Expand All @@ -15,7 +15,7 @@ WORKDIR /go-ethereum
RUN go run build/ci.go install -static ./cmd/geth

# Pull Geth into a second stage deploy alpine container
FROM alpine:3.15.7
FROM alpine:3.19

RUN apk add --no-cache ca-certificates

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/ethereum/go-ethereum

go 1.20
go 1.22.2

require (
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.2.0
Expand Down
2 changes: 1 addition & 1 deletion params/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const (
const (
BspVersionMajor = 1 // Major version component of the current release
BspVersionMinor = 8 // Minor version component of the current release
BspVersionPatch = 0 // Patch version component of the current release
BspVersionPatch = 1 // Patch version component of the current release
)

// Version holds the textual version string.
Expand Down

0 comments on commit 52fdf98

Please sign in to comment.