Fix variant image name generation

This commit is contained in:
BtbN 2020-09-27 23:40:54 +02:00
parent 2c7ef7efad
commit d809cc1020

View file

@ -73,14 +73,17 @@ jobs:
registry: docker.pkg.github.com registry: docker.pkg.github.com
username: ${{ github.actor }} username: ${{ github.actor }}
password: ${{ github.token }} password: ${{ github.token }}
- name: Pull latest - name: Image Name
run: docker pull docker.pkg.github.com/${GITHUB_REPOSITORY,,}/${{ matrix.target }}-${{ matrix.variant }}:latest || true id: imagename
- name: Build variant image
run: | run: |
IMG="docker.pkg.github.com/${GITHUB_REPOSITORY,,}/${{ matrix.target }}-${{ matrix.variant }}:latest" IMG="docker.pkg.github.com/${GITHUB_REPOSITORY,,}/${{ matrix.target }}-${{ matrix.variant }}:latest"
docker build --pull --cache-from "$IMG" --tag "$IMG" . echo "::set-output name=name::${IMG/ /-}"
- name: Pull latest
run: docker pull ${{ steps.imagename.outputs.name }} || true
- name: Build variant image
run: docker build --pull --cache-from ${{ steps.imagename.outputs.name }} --tag ${{ steps.imagename.outputs.name }} .
- name: Push variant image - name: Push variant image
run: docker push docker.pkg.github.com/${GITHUB_REPOSITORY,,}/${{ matrix.target }}-${{ matrix.variant }}:latest run: docker push ${{ steps.imagename.outputs.name }}
build_ffmpeg: build_ffmpeg:
name: Build ffmpeg name: Build ffmpeg
needs: build_targets needs: build_targets