Skip to content

Commit

Permalink
Update build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Uranite committed May 14, 2024
1 parent a8b5087 commit 901e94e
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,15 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Image Name
id: imagename
run: |
IMG="${GITHUB_REPOSITORY,,}/base"
echo "name=ghcr.io/${IMG/ /-}" >> $GITHUB_OUTPUT
echo "rawname=${IMG/ /-}" >> $GITHUB_OUTPUT
- name: Stop Commands
run: T="$(echo -n ${{ github.token }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
run: T="$(echo -n ${{ secrets.GITHUB_TOKEN }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
- name: Build target base image
uses: docker/build-push-action@v5
with:
Expand Down Expand Up @@ -94,7 +94,7 @@ jobs:
continue-on-error: true
uses: BtbN/delete-untagged-ghcr-action@main
with:
token: ${{ github.token }}
token: ${{ secrets.GITHUB_TOKEN }}
package_name: ${{ steps.imagename.outputs.rawname }}
repository_owner: ${{ github.repository_owner }}
repository: ${{ github.repository }}
Expand Down Expand Up @@ -123,7 +123,7 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Image Name
id: imagename
run: |
Expand All @@ -132,7 +132,7 @@ jobs:
echo "rawname=${IMG/ /-}" >> $GITHUB_OUTPUT
echo "gh_repo=${GITHUB_REPOSITORY,,}" >> $GITHUB_OUTPUT
- name: Stop Commands
run: T="$(echo -n ${{ github.token }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
run: T="$(echo -n ${{ secrets.GITHUB_TOKEN }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
- name: Build target base image
uses: docker/build-push-action@v5
with:
Expand All @@ -149,7 +149,7 @@ jobs:
continue-on-error: true
uses: BtbN/delete-untagged-ghcr-action@main
with:
token: ${{ github.token }}
token: ${{ secrets.GITHUB_TOKEN }}
package_name: ${{ steps.imagename.outputs.rawname }}
repository_owner: ${{ github.repository_owner }}
repository: ${{ github.repository }}
Expand Down Expand Up @@ -179,7 +179,7 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Image Name
id: imagename
run: |
Expand All @@ -191,7 +191,7 @@ jobs:
run: |
echo "dltagname=$(./util/get_dl_cache_tag.sh)" >> $GITHUB_OUTPUT
- name: Stop Commands
run: T="$(echo -n ${{ github.token }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
run: T="$(echo -n ${{ secrets.GITHUB_TOKEN }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
- name: Generate Dockerfile
run: ./generate.sh ${{ matrix.target }} ${{ matrix.variant }}
- name: Cache
Expand All @@ -214,7 +214,7 @@ jobs:
continue-on-error: true
uses: BtbN/delete-untagged-ghcr-action@main
with:
token: ${{ github.token }}
token: ${{ secrets.GITHUB_TOKEN }}
package_name: ${{ steps.imagename.outputs.rawname }}
repository_owner: ${{ github.repository_owner }}
repository: ${{ github.repository }}
Expand All @@ -240,10 +240,10 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build ffmpeg
run: |
T="$(echo -n ${{ github.token }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
T="$(echo -n ${{ secrets.GITHUB_TOKEN }} | sha256sum | head -c 64)" && echo -e "::add-mask::${T}\n::stop-commands::${T}"
./build.sh ${{ matrix.target }} ${{ matrix.variant }}
- name: Replace spaces in string
id: strs
Expand Down Expand Up @@ -284,7 +284,7 @@ jobs:
echo "tag_name=${TAGNAME}" >> $GITHUB_OUTPUT
echo "rel_date=${RELDATE}" >> $GITHUB_OUTPUT
env:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Update Latest
run: |
set -xe
Expand All @@ -297,12 +297,12 @@ jobs:
sleep 15
gh release create "$TAGNAME" --target "master" --title "$NAME" latest_artifacts/*
env:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Update Wiki
run: ./util/update_wiki.sh artifacts ${{ steps.create_release.outputs.tag_name }}
env:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Prune old releases
run: ./util/prunetags.sh
env:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 901e94e

Please sign in to comment.