-
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(container): ⚡ don't install mage for container build
- Loading branch information
Showing
1 changed file
with
3 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
|
||
FROM docker.io/alpine@sha256:0a4eaa0eecf5f8c050e5bba433f58c052be7587ee8af3e8b3910ef9ab5fbe9f5 AS builder | ||
# Copy go from official image. | ||
COPY --from=golang:1.23.1-alpine /usr/local/go/ /usr/local/go/ | ||
COPY --from=golang:1.23.2-alpine /usr/local/go/ /usr/local/go/ | ||
ENV PATH="/root/go/bin:/usr/local/go/bin:${PATH}" | ||
# Import TARGETPLATFORM. | ||
ARG TARGETPLATFORM | ||
|
@@ -15,12 +15,10 @@ WORKDIR /usr/src/go-hass-agent | |
ADD . . | ||
# install bash | ||
RUN apk update && apk add bash | ||
# install mage | ||
RUN go install github.com/magefile/[email protected] | ||
# install build dependencies | ||
RUN mage -v -d build/magefiles -w . preps:deps | ||
RUN go run github.com/magefile/mage -v -d build/magefiles -w . preps:deps | ||
# build the binary | ||
RUN mage -v -d build/magefiles -w . build:full | ||
RUN go run github.com/magefile/mage -v -d build/magefiles -w . build:full | ||
|
||
FROM docker.io/alpine@sha256:0a4eaa0eecf5f8c050e5bba433f58c052be7587ee8af3e8b3910ef9ab5fbe9f5 | ||
# Add image labels. | ||
|