Skip to content

Commit

Permalink
Tag images on push tag event
Browse files Browse the repository at this point in the history
  • Loading branch information
juanluisrp committed Mar 8, 2023
1 parent a779f45 commit fc01cc2
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 10 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ jobs:
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern=v{{version}}
type=semver,pattern=v{{major}}.{{minor}}
type=semver,pattern={{major}},enable=${{ !startsWith(github.ref, 'refs/tags/v0.') }}
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
type=raw,,value={{branch}}-{{sha}}
type=ref,event=tag
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=raw,value={{branch}}-{{sha}},enabled=${{ !startsWith(github.ref, 'refs/tags/') }}
-
name: Build image
uses: docker/build-push-action@v3
Expand Down
1 change: 0 additions & 1 deletion .space.kts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ job("Build, test and install ICAT project artifacts") {
BRANCH=${'$'}(echo ${'$'}JB_SPACE_GIT_BRANCH | cut -d'/' -f 3)
crane auth login geocat.registry.jetbrains.space -u ${'$'}JB_SPACE_CLIENT_ID -p ${'$'}JB_SPACE_CLIENT_SECRET
crane auth login ${'$'}GEOCAT_DOCKER_REGISTRY_URL -u ${'$'}GEOCAT_DOCKER_REGISTRY_USER -p ${'$'}GEOCAT_DOCKER_REGISTRY_PASSWORD
crane auth login ghcr.io -u ${'$'}GITHUB_REGISTRY_USERNAME -p ${'$'}GITHUB_REGISTRY_PAT
crane copy geocat.registry.jetbrains.space/p/jrc-inspire-portal/docker/icat:${'$'}BRANCH-${'$'}JB_SPACE_EXECUTION_NUMBER ${'$'}GEOCAT_DOCKER_REGISTRY_URL/jrc-inspire-portal/icat:${'$'}BRANCH-${'$'}JB_SPACE_EXECUTION_NUMBER
crane copy geocat.registry.jetbrains.space/p/jrc-inspire-portal/docker/icat:${'$'}BRANCH-${'$'}JB_SPACE_EXECUTION_NUMBER ${'$'}GEOCAT_DOCKER_REGISTRY_URL/jrc-inspire-portal/icat:${'$'}BRANCH
Expand Down
3 changes: 1 addition & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ RUN --mount=type=cache,target=/root/.m2/repository \

FROM eclipse-temurin:8-jre as finalImage

LABEL vendor="GeoCat B.V."
LABEL org.opencontainers.image.source https://github.com/GeoCat/icat
LABEL maintainer="GeoCat B.V."


# Check the file application.properties for a description of the environment variables that can be customized.
Expand Down
3 changes: 1 addition & 2 deletions DockerfileSpace
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ RUN java -Djarmode=layertools -jar icat.jar extract

FROM eclipse-temurin:8-jre as finalImage

LABEL vendor="GeoCat B.V."
LABEL org.opencontainers.image.source https://github.com/GeoCat/icat
LABEL maintainer="GeoCat B.V."


# Check the file application.properties for a description of the environment variables that can be customized.
Expand Down

0 comments on commit fc01cc2

Please sign in to comment.