mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-08-17 18:08:30 +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 }}
|
CHANNEL: ${{ inputs.channel }}
|
||||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||||
VERSION: ${{ inputs.version }}
|
VERSION: ${{ inputs.version }}
|
||||||
|
SERVICE: linux_${{ matrix.platform }}
|
||||||
run: |
|
run: |
|
||||||
mkdir ~/build
|
mkdir -p ~/build
|
||||||
cd bundle/docker
|
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 }}
|
sudo chown "${USER}:docker" ~/build/${{ matrix.exe }}
|
||||||
- name: Verify --update-to
|
- name: Verify --update-to
|
||||||
if: vars.UPDATE_TO_VERIFICATION && matrix.platform != 'armv7l'
|
if: vars.UPDATE_TO_VERIFICATION && matrix.platform != 'armv7l'
|
||||||
run: |
|
run: |
|
||||||
chmod +x ~/build/${{ matrix.exe }}
|
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)"
|
version="$(~/build/${{ matrix.exe }} --version)"
|
||||||
~/build/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
~/testing/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
||||||
downgraded_version="$(~/build/${{ matrix.exe }}_downgraded --version)"
|
downgraded_version="$(~/testing/${{ matrix.exe }}_downgraded --version)"
|
||||||
rm -f "${{ matrix.exe }}_downgraded"
|
|
||||||
[[ "$version" != "$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
|
- name: Upload artifacts
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
@ -209,21 +225,24 @@ jobs:
|
|||||||
CHANNEL: ${{ inputs.channel }}
|
CHANNEL: ${{ inputs.channel }}
|
||||||
ORIGIN: ${{ needs.process.outputs.origin }}
|
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||||
VERSION: ${{ inputs.version }}
|
VERSION: ${{ inputs.version }}
|
||||||
|
SERVICE: musllinux_${{ matrix.platform }}
|
||||||
run: |
|
run: |
|
||||||
mkdir ~/build
|
mkdir -p ~/build
|
||||||
cd bundle/docker
|
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 }}
|
sudo chown "${USER}:docker" ~/build/${{ matrix.exe }}
|
||||||
# - name: Verify --update-to
|
- name: Verify --update-to
|
||||||
# if: vars.UPDATE_TO_VERIFICATION
|
env:
|
||||||
# run: |
|
EXE_NAME: ${{ matrix.exe }}
|
||||||
# chmod +x ~/build/${{ matrix.exe }}
|
CHANNEL: ${{ inputs.channel }}
|
||||||
# cp ~/build/${{ matrix.exe }} ~/build/${{ matrix.exe }}_downgraded
|
ORIGIN: ${{ needs.process.outputs.origin }}
|
||||||
# version="$(~/build/${{ matrix.exe }} --version)"
|
VERSION: ${{ inputs.version }}
|
||||||
# ~/build/${{ matrix.exe }}_downgraded -v --update-to yt-dlp/yt-dlp@2023.03.04
|
SERVICE: musllinux_${{ matrix.platform }}_verify
|
||||||
# downgraded_version="$(~/build/${{ matrix.exe }}_downgraded --version)"
|
run: |
|
||||||
# rm -f "${{ matrix.exe }}_downgraded"
|
cd bundle/docker
|
||||||
# [[ "$version" != "$downgraded_version" ]]
|
docker compose up --build --exit-code-from "${SERVICE}" "${SERVICE}"
|
||||||
|
docker compose down
|
||||||
- name: Upload artifacts
|
- name: Upload artifacts
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
|
@ -44,14 +44,24 @@ services:
|
|||||||
CHANNEL: ${CHANNEL}
|
CHANNEL: ${CHANNEL}
|
||||||
ORIGIN: ${ORIGIN}
|
ORIGIN: ${ORIGIN}
|
||||||
VERSION: ${VERSION}
|
VERSION: ${VERSION}
|
||||||
PIP_EXTRA_INDEX_URL: https://www.piwheels.org/simple
|
|
||||||
PIP_PREFER_BINARY: "1"
|
|
||||||
USE_PYTHON_VERSION: "3.11"
|
|
||||||
SKIP_ONEDIR_BUILD: "1"
|
SKIP_ONEDIR_BUILD: "1"
|
||||||
volumes:
|
volumes:
|
||||||
- ~/build:/build
|
- ~/build:/build
|
||||||
- ../..:/yt-dlp
|
- ../..:/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:
|
musllinux_x86_64:
|
||||||
build:
|
build:
|
||||||
context: linux
|
context: linux
|
||||||
@ -68,6 +78,20 @@ services:
|
|||||||
- ~/build:/build
|
- ~/build:/build
|
||||||
- ../..:/yt-dlp
|
- ../..:/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:
|
musllinux_aarch64:
|
||||||
build:
|
build:
|
||||||
context: linux
|
context: linux
|
||||||
@ -83,3 +107,17 @@ services:
|
|||||||
volumes:
|
volumes:
|
||||||
- ~/build:/build
|
- ~/build:/build
|
||||||
- ../..:/yt-dlp
|
- ../..:/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