fix: something

This commit is contained in:
Aleksandr Chikovani 2023-08-26 22:15:51 -04:00
parent 43e6e86dc0
commit 811741a748
2 changed files with 27 additions and 26 deletions

View file

@ -46,28 +46,30 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
#- name: Login to GitHub Container Registry
# uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@2eb1c1961a95fc15694676618e422e8ba1d63825
with:
context: .
push: true
tags: ghcr.io/${{ env.IMAGE_NAME }}:${{ steps.semantic.outputs.release-version }}
labels: ${{ steps.meta.outputs.labels }}
build-args: |
VERSION=${{ steps.semantic.outputs.release-version }}
#- name: Build and push Docker image
# uses: docker/build-push-action@2eb1c1961a95fc15694676618e422e8ba1d63825
# with:
# context: .
# push: true
# tags: ghcr.io/${{ env.IMAGE_NAME }}:${{ steps.semantic.outputs.release-version }}
# labels: ${{ steps.meta.outputs.labels }}
# build-args: |
# VERSION=${{ steps.semantic.outputs.release-version }}
- name: Publish tag
uses: rickstaa/action-create-tag@07b918ecbf94359b859f25f7a70553a84e804923
with:
tag: ${{ steps.semantic.outputs.release-version }}
message: ${{ steps.semantic.outputs.name }}\n${{ steps.semantic.outputs.release-notes }}
#TODO: force_push_tag is true for debug purpose only
force_push_tag: true
outputs:
version: ${{ steps.semantic.outputs.release-version }}

View file

@ -1,12 +1,11 @@
FROM eclipse-temurin@sha256:039f727ed86402f37524b5d01a129947e2f061d5856901d07d73a454e689bb13 AS builder
# speed the things up
#ARG VERSION undefined
#ENV VERSION=$VERSION
#WORKDIR /app
#COPY . .
#RUN ./gradlew build -x test -Pversion=$VERSION
#
#FROM eclipse-temurin@sha256:e90e0d654765ab3ae33f5c5155daafa4a907d0d738ce98c3be8f402a8edcee2b
#ENV PORT 8080
#WORKDIR /app
#COPY --from=builder /app/build/libs/*jar .
ARG VERSION undefined
ENV VERSION=$VERSION
WORKDIR /app
COPY . .
RUN ./gradlew build -x test -Pversion=$VERSION
FROM eclipse-temurin@sha256:e90e0d654765ab3ae33f5c5155daafa4a907d0d738ce98c3be8f402a8edcee2b
ENV PORT 8080
WORKDIR /app
COPY --from=builder /app/build/libs/*jar .