Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .github/scripts/codec-checksums.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ set -euo pipefail
dockerfile=linux/Dockerfile
base=${1:?usage: codec-checksums.sh <base-ref>}
base_file=$(git show "${base}:${dockerfile}")
# To a file, not a pipe: curl truncates a file before a retry, but would append to a pipe.
tmp=$(mktemp)
trap 'rm -f "$tmp"' EXIT

while IFS='=' read -r var ver; do
lib=${var%_VERSION}
Expand All @@ -19,7 +22,8 @@ while IFS='=' read -r var ver; do
exit 1
fi
url=${template//"\${${var}}"/$ver}
sha=$(curl -fsSL --retry 3 "$url" | sha256sum | cut -d' ' -f1)
curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors -o "$tmp" "$url"
sha=$(sha256sum "$tmp" | cut -d' ' -f1)

sed "s/^ARG ${lib}_SHA256=.*/ARG ${lib}_SHA256=${sha}/" "$dockerfile" > "${dockerfile}.tmp"
mv "${dockerfile}.tmp" "$dockerfile"
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/validate-workflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,13 @@ jobs:
- name: Install actionlint
id: install
shell: bash
env:
ACTIONLINT_VERSION: v1.7.12
ACTIONLINT_SHA256: 8aca8db96f1b94770f1b0d72b6dddcb1ebb8123cb3712530b08cc387b349a3d8
run: |
# download-actionlint.bash pinned to the rhysd/actionlint v1.7.12 commit
# (immutable ref) so a re-pointed tag can't inject code into CI.
bash <(curl -sSfL https://raw.githubusercontent.com/rhysd/actionlint/914e7df21a07ef503a81201c76d2b11c789d3fca/scripts/download-actionlint.bash)
curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors -o actionlint.tar.gz "https://github.com/rhysd/actionlint/releases/download/${ACTIONLINT_VERSION}/actionlint_${ACTIONLINT_VERSION#v}_linux_amd64.tar.gz"
echo "${ACTIONLINT_SHA256} actionlint.tar.gz" | sha256sum -c -
tar xzf actionlint.tar.gz actionlint
echo "exe=$PWD/actionlint" >> "$GITHUB_OUTPUT"

- name: Run actionlint
Expand Down
10 changes: 5 additions & 5 deletions linux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -52,35 +52,35 @@ WORKDIR /src
# Usage handled inline per-library below.

# --- libmp3lame (LGPL) — MP3 encoding ---
RUN curl -fsSL "https://downloads.sourceforge.net/project/lame/lame/${LAME_VERSION}/lame-${LAME_VERSION}.tar.gz" -o lame.tar.gz \
RUN curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors "https://downloads.sourceforge.net/project/lame/lame/${LAME_VERSION}/lame-${LAME_VERSION}.tar.gz" -o lame.tar.gz \
&& echo "${LAME_SHA256} lame.tar.gz" | sha256sum -c - \
&& tar xf lame.tar.gz && cd "lame-${LAME_VERSION}" \
&& ./configure --prefix="${PREFIX}" --enable-static --disable-shared --disable-frontend \
&& make -j"$(nproc)" && make install

# --- libogg (BSD) — container for Vorbis ---
RUN curl -fsSL "https://downloads.xiph.org/releases/ogg/libogg-${OGG_VERSION}.tar.xz" -o ogg.tar.xz \
RUN curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors "https://downloads.xiph.org/releases/ogg/libogg-${OGG_VERSION}.tar.xz" -o ogg.tar.xz \
&& echo "${OGG_SHA256} ogg.tar.xz" | sha256sum -c - \
&& tar xf ogg.tar.xz && cd "libogg-${OGG_VERSION}" \
&& ./configure --prefix="${PREFIX}" --enable-static --disable-shared \
&& make -j"$(nproc)" && make install

# --- libvorbis (BSD) — Vorbis encoding ---
RUN curl -fsSL "https://downloads.xiph.org/releases/vorbis/libvorbis-${VORBIS_VERSION}.tar.xz" -o vorbis.tar.xz \
RUN curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors "https://downloads.xiph.org/releases/vorbis/libvorbis-${VORBIS_VERSION}.tar.xz" -o vorbis.tar.xz \
&& echo "${VORBIS_SHA256} vorbis.tar.xz" | sha256sum -c - \
&& tar xf vorbis.tar.xz && cd "libvorbis-${VORBIS_VERSION}" \
&& ./configure --prefix="${PREFIX}" --enable-static --disable-shared \
&& make -j"$(nproc)" && make install

# --- libopus (BSD) — Opus encoding/decoding ---
RUN curl -fsSL "https://downloads.xiph.org/releases/opus/opus-${OPUS_VERSION}.tar.gz" -o opus.tar.gz \
RUN curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors "https://downloads.xiph.org/releases/opus/opus-${OPUS_VERSION}.tar.gz" -o opus.tar.gz \
&& echo "${OPUS_SHA256} opus.tar.gz" | sha256sum -c - \
&& tar xf opus.tar.gz && cd "opus-${OPUS_VERSION}" \
&& ./configure --prefix="${PREFIX}" --enable-static --disable-shared \
&& make -j"$(nproc)" && make install

# --- opencore-amr (Apache-2.0) — AMR-NB encoding (Sleezer AMR target) ---
RUN curl -fsSL "https://downloads.sourceforge.net/opencore-amr/opencore-amr-${OPENCORE_AMR_VERSION}.tar.gz" -o amr.tar.gz \
RUN curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors "https://downloads.sourceforge.net/opencore-amr/opencore-amr-${OPENCORE_AMR_VERSION}.tar.gz" -o amr.tar.gz \
&& echo "${OPENCORE_AMR_SHA256} amr.tar.gz" | sha256sum -c - \
&& tar xf amr.tar.gz && cd "opencore-amr-${OPENCORE_AMR_VERSION}" \
&& ./configure --prefix="${PREFIX}" --enable-static --disable-shared \
Expand Down
13 changes: 12 additions & 1 deletion renovate.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": ["github>chodeus/chodeus-ops"],
"gitIgnoredAuthors": ["41898282+github-actions[bot]@users.noreply.github.com"]
"customManagers": [
{
"customType": "regex",
"description": "actionlint's release tag and tarball SHA-256 in validate-workflows.yml; Renovate takes the same asset's hash from the new release.",
"managerFilePatterns": ["/^\\.github/workflows/validate-workflows\\.yml$/"],
"matchStrings": [
"ACTIONLINT_VERSION:\\s*(?<currentValue>v[^\\s]+)\\s+ACTIONLINT_SHA256:\\s*(?<currentDigest>[a-f0-9]{64})"
],
"datasourceTemplate": "github-release-attachments",
"depNameTemplate": "rhysd/actionlint"
}
]
}
Loading