Use Docker Hub...

This commit is contained in:
BtbN 2020-09-03 03:13:45 +02:00
parent 04b18a170b
commit a7ade4dc87
5 changed files with 20 additions and 19 deletions

View file

@ -9,13 +9,14 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Pull latest
run: docker pull btbn/ffmpeg-builder:base || true
- name: Build and push base
uses: docker/build-push-action@v1
with:
username: BtbN
password: ${{ secrets.REG_TOKEN }}
registry: docker.pkg.github.com
repository: btbn/ffmpeg-build/builder
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_TOKEN }}
repository: btbn/ffmpeg-builder
tags: base
path: base
build_target_bases:
@ -28,13 +29,14 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Pull latest
run: docker pull btbn/ffmpeg-builder:base-${{ matrix.target }} || true
- name: Build and push target base
uses: docker/build-push-action@v1
with:
username: BtbN
password: ${{ secrets.REG_TOKEN }}
registry: docker.pkg.github.com
repository: btbn/ffmpeg-build/builder
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_TOKEN }}
repository: btbn/ffmpeg-builder
tags: base-${{ matrix.target }}
path: base-${{ matrix.target }}
build_targets:
@ -50,11 +52,12 @@ jobs:
uses: actions/checkout@v2
- name: Generate Dockerfile
run: ./generate.sh ${{ matrix.target }} ${{ matrix.variant }}
- name: Pull latest
run: docker pull btbn/ffmpeg-builder:${{ matrix.target }}-${{ matrix.variant }} || true
- name: Build and push target base
uses: docker/build-push-action@v1
with:
username: BtbN
password: ${{ secrets.REG_TOKEN }}
registry: docker.pkg.github.com
repository: btbn/ffmpeg-build/builder
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_TOKEN }}
repository: btbn/ffmpeg-builder
tags: ${{ matrix.target }}-${{ matrix.variant }}

View file

@ -1,4 +1,4 @@
FROM docker.pkg.github.com/btbn/ffmpeg-builds/builder:base
FROM btbn/ffmpeg-builder:base
ENV DEBIAN_FRONTEND noninteractive

View file

@ -10,7 +10,7 @@ to_df() {
echo >> Dockerfile
}
to_df "FROM $REPO/builder:base-$TARGET"
to_df "FROM $REPO:base-$TARGET"
to_df "ENV TARGET $TARGET"
to_df "ENV VARIANT $VARIANT"
to_df "ENV REPO $REPO"

View file

@ -5,4 +5,4 @@ source util/vars.sh
./generate.sh "$TARGET" "$VARIANT"
exec docker build -t "$REPO/$TARGET-$VARIANT:latest" .
exec docker build -t "$IMAGE" .

View file

@ -7,7 +7,5 @@ fi
TARGET="$1"
VARIANT="${2:-gpl}"
REPO="docker.pkg.github.com/${GITHUB_REPOSITORY:-btbn/ffmpeg-builds}"
REPO="${REPO,,}"
IMAGE="$REPO/$TARGET-$VARIANT:latest"
REPO="${DOCKER_REPO:-btbn/ffmpeg-builder}"
IMAGE="$REPO:$TARGET-$VARIANT"