3 ms·
I like this approach as well, though I typically include a `Dockerfile` in my Go projects so my run task is just: - name: Build run: docker build -t
by tomphoolery 7y ago
I like this approach as well, though I typically include a `Dockerfile` in my Go projects so my run task is just:
- name: Build
run: docker build -t me/image:latest .
env:
DOCKER_BUILDKIT: 1
GOOS: ${{ matrix.os }}
GOARCH: ${{ matrix.arch }}
- ReidZB 7y agoAh, well, the output of what I wrote above isn't actually a Docker image. It ends up writing a cross-compiled binary to the local FS, which I then later attach to a GitHub Release. (The goal was to automatically attach platform binaries to a release once it was made.) ...unless your Dockerfile ends up doing that too? If so I'd be interested to see it if you're willing to share!