Last active
May 20, 2025 08:51
-
-
Save GluTbl/cfcccda5b8307695b8ef2b08c808343b to your computer and use it in GitHub Desktop.
[AAXtoMP3 Dockerfile] #docker
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:18.04 | |
ENV DEBIAN_FRONTEND=noninteractive | |
# Install core dependencies | |
RUN apt-get update && apt-get install -y \ | |
curl \ | |
bash \ | |
grep \ | |
sed \ | |
findutils \ | |
jq \ | |
curl \ | |
bc \ | |
unzip \ | |
git \ | |
python3 \ | |
python3-pip \ | |
mp4v2-utils \ | |
mediainfo \ | |
ca-certificates \ | |
&& apt-get clean | |
# Install FFmpeg (static build from John Van Sickle) | |
RUN curl -L https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-amd64-static.tar.xz -o ffmpeg.tar.xz && \ | |
mkdir /ffmpeg && \ | |
tar -xf ffmpeg.tar.xz -C /ffmpeg --strip-components=1 && \ | |
mv /ffmpeg/ffmpeg /usr/local/bin/ && \ | |
mv /ffmpeg/ffprobe /usr/local/bin/ && \ | |
rm -rf /ffmpeg ffmpeg.tar.xz | |
# Check version | |
RUN ffmpeg -version | |
RUN mkdir input | |
RUN mkdir output | |
# Set working directory | |
WORKDIR /app | |
# Clone the AAXtoMP3 repo | |
RUN git clone https://github.com/KrumpetPirate/AAXtoMP3.git . | |
RUN sed -i '684i\ title=$(slugify "$title")' AAXtoMP3 && \ | |
sed -i '684i\ artist=$(slugify "$artist")' AAXtoMP3 && \ | |
sed -i '684i\ genre=$(slugify "$genre")' AAXtoMP3 | |
RUN sed -i '2i\ | |
slugify() { local input="$1"; local safe=$(echo "$input" | tr -cd '\''[:alnum:] _'\'' ); echo "$safe"; }' AAXtoMP3 | |
# Make script executable | |
RUN chmod +x AAXtoMP3 | |
# Default shell, can be overridden | |
CMD ["/bin/bash"] | |
# docker build -t aaxtomp3:latest . | |
# docker run --rm -it --name aaxtomp3-shell -v "D:\Audible\input":/input -v "D:\Audible\output":/output -w /app aaxtomp3:latest bash | |
# ./AAXtoMP3 --authcode AUTHCODE_HERE -e:mp3 --level 4 --chaptered --loglevel 1 -t /output /input/*.aax | |
# for f in /input/*.aaxc; do ./AAXtoMP3 -e:mp3 --level 4 --chaptered --loglevel 1 -t /output "$f" ; done | |
# for f in /input/*.aaxc; do ./AAXtoMP3 -e:mp3 --level 4 --loglevel 1 -t /output "$f" ; done | |
# for f in /input/*.aax; do ./AAXtoMP3 --authcode AUTHCODE_HERE -e:mp3 --level 4 --loglevel 1 -t /output "$f" ; done | |
# find . -type f ! -name "*.sha256sum" -exec bash -c 'for f; do echo "Processing: $f"; (cd "$(dirname "$f")" && sha256sum "$(basename "$f")" > "$(basename "$f").sha256sum"); done' _ {} + | |
# find . -type f ! -name "*.sha256sum" -exec sh -c 'for f; do echo "Processing: $f"; (cd "$(dirname "$f")" && sha256sum "$(basename "$f")" > "$(basename "$f").sha256sum"); done' _ {} + | |
# audible download --all --aaxc --chapter --cover | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment