Skip to content

[houskeeping] deps

[houskeeping] deps #11

Workflow file for this run

name: Deploy
on: [push]
jobs:
build:
runs-on: "ubuntu-latest"
steps:
- name: "Checkout code"
uses: "actions/checkout@v2"
- uses: actions/setup-go@v2
with:
go-version: '^1.18'
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Prep binary dirs
run: |
mkdir -p linux/amd64
mkdir -p linux/arm64
- name: Build amd64 binary
env:
GOOS: linux
GOARCH: amd64
CGO_ENABLED: 0
run: go build -o linux/amd64/main main.go
- name: Build arm64 binary
env:
GOOS: linux
GOARCH: arm64
CGO_ENABLED: 0
run: go build -o linux/arm64/main main.go
- name: Docker login
run: echo ${{ secrets.GHCR_TOKEN }} | docker login ghcr.io --username lispyclouds --password-stdin
- name: Build and push image
run: docker buildx build --push --platform linux/amd64,linux/arm64 -t ghcr.io/bob-cd/resource-git:latest .