diff --git a/.github/workflows/release-gh-image.yaml b/.github/workflows/release-gh-image.yaml index 9dfd8b9..f19d5f3 100644 --- a/.github/workflows/release-gh-image.yaml +++ b/.github/workflows/release-gh-image.yaml @@ -44,7 +44,9 @@ jobs: with: context: . push: true - tags: "${{ steps.meta.outputs.tags }}-slim" + tags: | + ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.meta.outputs.version }}-slim + ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest-slim target: "slim" labels: ${{ steps.meta.outputs.labels }} - name: Build and push Docker image Static (distroless) @@ -52,6 +54,8 @@ jobs: with: context: . push: true - tags: "${{ steps.meta.outputs.tags }}-static" + tags: | + ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.meta.outputs.version }}-static + ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest-static labels: ${{ steps.meta.outputs.labels }} target: "static" \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 27aeee8..3128415 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,11 @@ FROM golang:latest AS builder RUN mkdir /app - COPY go.mod /app/ COPY go.sum /app/ - WORKDIR /app - RUN go mod download - COPY ./ /app - RUN CGO_ENABLED=0 go build -o crontab-go RUN chmod +x crontab-go