Skip to content

Instantly share code, notes, and snippets.

@solsson
Last active November 9, 2021 12:05
Show Gist options
  • Save solsson/327382404f600736316316fee86f6b9f to your computer and use it in GitHub Desktop.
Save solsson/327382404f600736316316fee86f6b9f to your computer and use it in GitHub Desktop.
Build google/oauth2l locally, current golang and M1 cpu support
version: '2.1'
services:
build:
user: ${UID}
image: golang:1.17.3-bullseye
volumes:
- .:/workspace/source
entrypoint:
- /bin/bash
- -cex
- |
cd /workspace/source
sed -i 's/go 1\.13/go 1.17/' go.mod
sed -i 's/= darwin linux windows/= darwin linux/' Makefile
sed -i 's/= amd64/= arm64 amd64/' Makefile
go mod tidy
go mod vendor
git diff --stat
git diff go.mod
make test
make build
make compress
(cd build/; sha256sum *.tgz | tee sha256sum.txt)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment