From 429c05f5b722ceda5fa3511871f37e290070b540 Mon Sep 17 00:00:00 2001 From: Jacob Gadikian Date: Tue, 31 Jan 2023 10:01:18 +0700 Subject: [PATCH 1/3] use golang 1.19 to make mixed runtimes impossible --- go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 8b63a37a..ca4cbebc 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/terra-money/alliance -go 1.18 +go 1.19 require ( cosmossdk.io/errors v1.0.0-beta.7 From 48a4d25c7994454ab8b37946639006e658250efc Mon Sep 17 00:00:00 2001 From: emidev98 Date: Tue, 31 Jan 2023 09:57:35 +0200 Subject: [PATCH 2/3] feat: golang 19 in docs and Dockerfile --- README.md | 2 +- scripts/containers/Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index bd52d1c8..a7fbb121 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ By design, x/alliance use the following CosmosSDK modules to implement interchai # Development environment -This project uses [Go v1.18](https://go.dev/dl/) and was bootstrapped with [Ignite CLI v0.25.1](https://docs.ignite.com/). However, for ease of upgrade, ignite has been removed in favor of manual workflows. +This project uses [Go v1.19](https://go.dev/dl/) and was bootstrapped with [Ignite CLI v0.25.1](https://docs.ignite.com/). However, for ease of upgrade, ignite has been removed in favor of manual workflows. To run the local development environment use: ``` diff --git a/scripts/containers/Dockerfile b/scripts/containers/Dockerfile index a15e116f..43bef3f8 100644 --- a/scripts/containers/Dockerfile +++ b/scripts/containers/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.18.7-bullseye AS build +FROM golang:1.19-bullseye AS build RUN apt update && apt install jq build-essential -y From e148cd0d323cccea2ddbbb3e4282149fd6add35c Mon Sep 17 00:00:00 2001 From: Jacob Gadikian Date: Wed, 1 Feb 2023 05:37:09 +0700 Subject: [PATCH 3/3] automated docker builds --- .github/workflows/docker.yml | 37 ++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/docker.yml diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml new file mode 100644 index 00000000..3985b5dd --- /dev/null +++ b/.github/workflows/docker.yml @@ -0,0 +1,37 @@ +name: docker + +on: + push: + branches: + - 'main' + +jobs: + docker: + runs-on: ubuntu-latest + steps: + - + name: Checkout + uses: actions/checkout@v3 + - + name: Set up QEMU + uses: docker/setup-qemu-action@v2 + - + name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - + name: Login to GHCR + if: github.event_name != 'pull_request' + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.GITHUB_TOKEN }} + + - + name: Build and push + uses: docker/build-push-action@v4 + with: + file: scripts/containers/Dockerfile + context: . + push: ${{ github.event_name != 'pull_request' }} + tags: user/app:latest