Skip to content

Commit

Permalink
feat: Add archwayd darwin binaries to release pipeline (#421)
Browse files Browse the repository at this point in the history
* feat: Add archwayd darwin binaries to release pipeline

* chore: Update CHANGELOG
  • Loading branch information
kayano authored Jul 21, 2023
1 parent ede09d0 commit 535d0eb
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 17 deletions.
7 changes: 0 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,6 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to GHCR
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: GoReleaser
run: make release
env:
Expand Down
76 changes: 72 additions & 4 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ before:
hooks:
- wget https://github.com/CosmWasm/wasmvm/releases/download/{{ .Env.LIBWASM_VERSION }}/libwasmvm_muslc.x86_64.a -O /lib/libwasmvm_muslc.a
- wget https://github.com/CosmWasm/wasmvm/releases/download/{{ .Env.LIBWASM_VERSION }}/libwasmvm_muslc.aarch64.a -O /usr/local/lib/libwasmvm_muslc.a
- apt install musl-dev=1.2.2-1
- wget https://github.com/CosmWasm/wasmvm/releases/download/{{ .Env.LIBWASM_VERSION }}/libwasmvmstatic_darwin.a -O /lib/libwasmvmstatic_darwin.a
- apt update && apt install musl-dev=1.2.2-1
env:
- CGO_ENABLED=1
builds:
Expand Down Expand Up @@ -46,37 +47,104 @@ builds:
tags:
- netgo
- muslc
- id: archwayd-darwin-amd64
main: ./cmd/archwayd
binary: archwayd
env:
- CC=o64-clang
- CGO_LDFLAGS=-L/lib
goos:
- darwin
goarch:
- amd64
flags:
- -mod=readonly
- -trimpath
ldflags:
- -X main.commit={{ .Commit }}
- -X main.date={{ .CommitDate }}
- -X github.com/cosmos/cosmos-sdk/version.Name=archway
- -X github.com/cosmos/cosmos-sdk/version.AppName=archway
- -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,static_wasm
- -w -s
- -linkmode=external
tags:
- netgo
- ledger
- static_wasm
- id: archwayd-darwin-arm64
main: ./cmd/archwayd
binary: archwayd
env:
- CC=oa64-clang
- CGO_LDFLAGS=-L/lib
goos:
- darwin
goarch:
- arm64
flags:
- -mod=readonly
- -trimpath
ldflags:
- -X main.commit={{ .Commit }}
- -X main.date={{ .CommitDate }}
- -X github.com/cosmos/cosmos-sdk/version.Name=archway
- -X github.com/cosmos/cosmos-sdk/version.AppName=archway
- -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,static_wasm
- -w -s
- -linkmode=external
tags:
- netgo
- ledger
- static_wasm
universal_binaries:
- id: archwayd-darwin-all
ids:
- archwayd-darwin-amd64
- archwayd-darwin-arm64
replace: false
name_template: "{{ .ProjectName }}d"
release:
skip_upload: '{{ if eq .Env.RELEASE "true" }}false{{else}}true{{end}}'
archives:
- id: w/version
builds:
- archwayd-linux-amd64
- archwayd-linux-arm64
- archwayd-darwin-amd64
- archwayd-darwin-arm64
- archwayd-darwin-all
name_template: '{{ .ProjectName }}d_v{{ .Version }}_{{ .Os }}_{{ .Arch }}'
wrap_in_directory: false
format: zip
rlcp: true
files:
- none*
- id: wo/version
builds:
- archwayd-linux-amd64
- archwayd-linux-arm64
- archwayd-darwin-amd64
- archwayd-darwin-arm64
- archwayd-darwin-all
name_template: '{{ .ProjectName }}d_{{ .Os }}_{{ .Arch }}'
wrap_in_directory: false
format: zip
rlcp: true
files:
- none*
- id: binary
builds:
- archwayd-linux-amd64
- archwayd-linux-arm64
- archwayd-darwin-amd64
- archwayd-darwin-arm64
- archwayd-darwin-all
name_template: '{{ .ProjectName }}d_{{ .Os }}_{{ .Arch }}'
wrap_in_directory: false
format: binary
rlcp: true
files:
- none*
checksum:
Expand Down
8 changes: 4 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

<!--
<!--
### Added
Contains the new features.
Expand All @@ -25,15 +25,15 @@ Contains bug fixes.
### Improvements
Contains all the PRs that improved the code without changing the behaviours.
Contains all the PRs that improved the code without changing the behaviours.
-->

## [Unreleased]

### Added

- [#419](https://github.com/archway-network/archway/pull/419) - Easily run localnet via make

- [#421](https://github.com/archway-network/archway/pull/421) - Add archwayd darwin binaries

## [v2.0.0]

Expand All @@ -43,7 +43,7 @@ Contains all the PRs that improved the code without changing the behaviours.

### Fixed

- [#414](https://github.com/archway-network/archway/pull/414) - Preventing user from setting contract flat fee if rewards address is not set
- [#414](https://github.com/archway-network/archway/pull/414) - Preventing user from setting contract flat fee if rewards address is not set
- [#418](https://github.com/archway-network/archway/pull/418) - Fixing authz msg decoding in x/rewards antehandlers

## [v1.0.1]
Expand Down
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ LEDGER_ENABLED ?= true
# SDK_PACK := $(shell go list -m github.com/cosmos/cosmos-sdk | sed 's/ /\@/g')
BINDIR ?= $(GOPATH)/bin
SIMAPP = ./app
GORELEASER_VERSION = v1.19.5
GORELEASER_VERSION = v1.20.6

# for dockerized protobuf tools
DOCKER := $(shell which docker)
Expand Down Expand Up @@ -242,7 +242,6 @@ release:
-e LIBWASM_VERSION=$(LIBWASM_VERSION) \
-e RELEASE=$(RELEASE) \
-e GITHUB_TOKEN="$(GITHUB_TOKEN)" \
-v $(HOME)/.docker/config.json:/root/.docker/config.json \
-v /var/run/docker.sock:/var/run/docker.sock \
-v `pwd`:/go/src/github.com/archway-network/archway \
-w /go/src/github.com/archway-network/archway \
Expand Down

0 comments on commit 535d0eb

Please sign in to comment.