Closed vipulg13 closed 5 months ago
Instead of rwynn/monstache-builder-cache-rel6
, you can simply use latest golang alpine images from dockerhub and add this to the dockerfile:
FROM golang:<alpine-latest-tag> As build
RUN apk add --no-cache gcc musl-dev
COPY monstache code and plugin and build using this image
Instead of rwynn/monstache-alpine
, you some latest alpine image from dockerhub and:
FROM <alpine_latest_image>as final
COPY --from=build /app/build/linux-amd64/monstache /bin/monstache
COPY --from=build /app/build/plugin.so /bin/plugin.so`
and update the go.mod to use the same go version as that of your golang docker image in your source code.
@Joey0538 thank you for your comments. I was aware of this builder Dockerfile, but I was not sure whether that is up to date. My multi-stage custom build was successful.
Dear @rwynn, could you please provide me with the Dockerfiles for the base images
rwynn/monstache-alpine
andrwynn/monstache-builder-cache-rel6
, used for the final monstache build? Due to my institute's internal security policies, I must use the updated alpine and golang images in my build.