mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-08-17 09:58:29 +00:00
Verify armv7l and musllinux exes, do not use piwheels
Authored by: bashonly
This commit is contained in:
parent
b4c7dadad6
commit
b6030e71ae
55
.github/workflows/build.yml
vendored
55
.github/workflows/build.yml
vendored
@ -164,21 +164,37 @@ jobs:
|
||||
CHANNEL: ${{ inputs.channel }}
|
||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||
VERSION: ${{ inputs.version }}
|
||||
SERVICE: linux_${{ matrix.platform }}
|
||||
run: |
|
||||
mkdir ~/build
|
||||
mkdir -p ~/build
|
||||
cd bundle/docker
|
||||
docker compose up --build linux_${{ matrix.platform }}
|
||||
docker compose up --build --exit-code-from "${SERVICE}" "${SERVICE}"
|
||||
docker compose down
|
||||
sudo chown "${USER}:docker" ~/build/${{ matrix.exe }}
|
||||
- name: Verify --update-to
|
||||
if: vars.UPDATE_TO_VERIFICATION && matrix.platform != 'armv7l'
|
||||
run: |
|
||||
chmod +x ~/build/${{ matrix.exe }}
|
||||
cp ~/build/${{ matrix.exe }} ~/build/${{ matrix.exe }}_downgraded
|
||||
mkdir -p ~/testing
|
||||
cp ~/build/${{ matrix.exe }} ~/testing/${{ matrix.exe }}_downgraded
|
||||
version="$(~/build/${{ matrix.exe }} --version)"
|
||||
~/build/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
||||
downgraded_version="$(~/build/${{ matrix.exe }}_downgraded --version)"
|
||||
rm -f "${{ matrix.exe }}_downgraded"
|
||||
~/testing/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
||||
downgraded_version="$(~/testing/${{ matrix.exe }}_downgraded --version)"
|
||||
[[ "$version" != "$downgraded_version" ]]
|
||||
# TEMPORARY:
|
||||
~/build/${{ matrix.exe }} -v --print-traffic -o- --impersonate chrome "https://tls.browserleaks.com/json" | cat
|
||||
- name: Verify --update-to for armv7l
|
||||
if: vars.UPDATE_TO_VERIFICATION && matrix.platform == 'armv7l'
|
||||
env:
|
||||
EXE_NAME: ${{ matrix.exe }}
|
||||
CHANNEL: ${{ inputs.channel }}
|
||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||
VERSION: ${{ inputs.version }}
|
||||
SERVICE: linux_${{ matrix.platform }}_verify
|
||||
run: |
|
||||
cd bundle/docker
|
||||
docker compose up --build --exit-code-from "${SERVICE}" "${SERVICE}"
|
||||
docker compose down
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
@ -209,21 +225,24 @@ jobs:
|
||||
CHANNEL: ${{ inputs.channel }}
|
||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||
VERSION: ${{ inputs.version }}
|
||||
SERVICE: musllinux_${{ matrix.platform }}
|
||||
run: |
|
||||
mkdir ~/build
|
||||
mkdir -p ~/build
|
||||
cd bundle/docker
|
||||
docker compose up --build musllinux_${{ matrix.platform }}
|
||||
docker compose up --build --exit-code-from "${SERVICE}" "${SERVICE}"
|
||||
docker compose down
|
||||
sudo chown "${USER}:docker" ~/build/${{ matrix.exe }}
|
||||
# - name: Verify --update-to
|
||||
# if: vars.UPDATE_TO_VERIFICATION
|
||||
# run: |
|
||||
# chmod +x ~/build/${{ matrix.exe }}
|
||||
# cp ~/build/${{ matrix.exe }} ~/build/${{ matrix.exe }}_downgraded
|
||||
# version="$(~/build/${{ matrix.exe }} --version)"
|
||||
# ~/build/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
||||
# downgraded_version="$(~/build/${{ matrix.exe }}_downgraded --version)"
|
||||
# rm -f "${{ matrix.exe }}_downgraded"
|
||||
# [[ "$version" != "$downgraded_version" ]]
|
||||
- name: Verify --update-to
|
||||
env:
|
||||
EXE_NAME: ${{ matrix.exe }}
|
||||
CHANNEL: ${{ inputs.channel }}
|
||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||
VERSION: ${{ inputs.version }}
|
||||
SERVICE: musllinux_${{ matrix.platform }}_verify
|
||||
run: |
|
||||
cd bundle/docker
|
||||
docker compose up --build --exit-code-from "${SERVICE}" "${SERVICE}"
|
||||
docker compose down
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
|
@ -44,14 +44,24 @@ services:
|
||||
CHANNEL: ${CHANNEL}
|
||||
ORIGIN: ${ORIGIN}
|
||||
VERSION: ${VERSION}
|
||||
PIP_EXTRA_INDEX_URL: https://www.piwheels.org/simple
|
||||
PIP_PREFER_BINARY: "1"
|
||||
USE_PYTHON_VERSION: "3.11"
|
||||
SKIP_ONEDIR_BUILD: "1"
|
||||
volumes:
|
||||
- ~/build:/build
|
||||
- ../..:/yt-dlp
|
||||
|
||||
linux_armv7l_verify:
|
||||
build:
|
||||
context: linux
|
||||
dockerfile: verify.Dockerfile
|
||||
platforms:
|
||||
- "linux/arm/v7"
|
||||
args:
|
||||
IMAGE: arm32v7/debian:bullseye
|
||||
environment:
|
||||
EXE_NAME: ${EXE_NAME}
|
||||
volumes:
|
||||
- ~/build:/build
|
||||
|
||||
musllinux_x86_64:
|
||||
build:
|
||||
context: linux
|
||||
@ -68,6 +78,20 @@ services:
|
||||
- ~/build:/build
|
||||
- ../..:/yt-dlp
|
||||
|
||||
musllinux_x86_64_verify:
|
||||
build:
|
||||
context: linux
|
||||
dockerfile: verify.Dockerfile
|
||||
platforms:
|
||||
- "linux/amd64"
|
||||
args:
|
||||
IMAGE: alpine:3.22
|
||||
environment:
|
||||
EXE_NAME: ${EXE_NAME}
|
||||
SKIP_UPDATE_TO: "1"
|
||||
volumes:
|
||||
- ~/build:/build
|
||||
|
||||
musllinux_aarch64:
|
||||
build:
|
||||
context: linux
|
||||
@ -83,3 +107,17 @@ services:
|
||||
volumes:
|
||||
- ~/build:/build
|
||||
- ../..:/yt-dlp
|
||||
|
||||
musllinux_aarch64_verify:
|
||||
build:
|
||||
context: linux
|
||||
dockerfile: verify.Dockerfile
|
||||
platforms:
|
||||
- "linux/arm64"
|
||||
args:
|
||||
IMAGE: alpine:3.22
|
||||
environment:
|
||||
EXE_NAME: ${EXE_NAME}
|
||||
SKIP_UPDATE_TO: "1"
|
||||
volumes:
|
||||
- ~/build:/build
|
||||
|
7
bundle/docker/linux/verify.Dockerfile
Normal file
7
bundle/docker/linux/verify.Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
ARG IMAGE=alpine:3.22
|
||||
|
||||
FROM $IMAGE AS image
|
||||
|
||||
WORKDIR /testing
|
||||
COPY verify.sh /verify.sh
|
||||
ENTRYPOINT /verify.sh
|
22
bundle/docker/linux/verify.sh
Executable file
22
bundle/docker/linux/verify.sh
Executable file
@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
set -exuo
|
||||
|
||||
chmod +x /build/${EXE_NAME}
|
||||
|
||||
if [ -n "${SKIP_UPDATE_TO:-}" ]; then
|
||||
/build/${EXE_NAME} -v || true
|
||||
/build/${EXE_NAME} --version
|
||||
|
||||
# TEMPORARY:
|
||||
/build/${EXE_NAME} -v --print-traffic -o- --impersonate chrome "https://tls.browserleaks.com/json" | cat
|
||||
|
||||
exit 0
|
||||
fi
|
||||
|
||||
cp /build/${EXE_NAME} ./${EXE_NAME}_downgraded
|
||||
version="$(/build/${EXE_NAME} --version)"
|
||||
./${EXE_NAME}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
||||
downgraded_version="$(./${EXE_NAME}_downgraded --version)"
|
||||
if [ "${version}" = "${downgraded_version}" ]; then
|
||||
exit 1
|
||||
fi
|
Loading…
Reference in New Issue
Block a user