refactor: no need to tag OCELOT_VERSION

Now we have the version in a file, it's not necessary to encode it in the docker tag.
This commit is contained in:
Robert Schäfer 2024-10-29 17:41:17 +01:00
parent 6652a02c87
commit be5bcf8faa

View File

@ -32,21 +32,21 @@ jobs:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Read $OCELOT_VERSION from file
run: cat .env >> $GITHUB_ENV
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@70b2cdc6480c1a8b86edf1777157f8f437de2166
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=schedule,prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=semver,pattern={{version}},prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=semver,pattern={{major}}.{{minor}},prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=semver,pattern={{major}},prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=ref,event=branch,prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=ref,event=pr,prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-
type=sha,prefix=ocelot-${{ env.OCELOT_VERSION }}--branded-sha-
type=schedule
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=ref,event=branch
type=ref,event=pr
type=sha
- name: Read $OCELOT_VERSION from file
run: cat .env >> $GITHUB_ENV
- name: Build and push Docker images
id: push
uses: docker/build-push-action@4f58ea79222b3b9dc2c8bbdd6debcef730109a75