first commit
This commit is contained in:
+11
@@ -0,0 +1,11 @@
|
||||
FROM alpine:3.22.4
|
||||
USER root
|
||||
RUN apk upgrade --no-cache
|
||||
RUN apk add --no-cache ffmpeg mutagen curl
|
||||
RUN curl -L https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp -o /yt-dlp
|
||||
RUN chmod a+rx /yt-dlp
|
||||
COPY . .
|
||||
RUN mkdir /download
|
||||
RUN mkdir /music
|
||||
RUN chmod +x download.sh
|
||||
CMD ["sh", "./download.sh"]
|
||||
@@ -0,0 +1,17 @@
|
||||
services:
|
||||
yt-downloader:
|
||||
build: .
|
||||
image: yt-downloader
|
||||
container_name: yt-downloader
|
||||
volumes:
|
||||
- ./error:/error
|
||||
- ./yt-downloader/:/music
|
||||
restart: "unless-stopped"
|
||||
environment:
|
||||
PLAYLIST_URL: "https://www.youtube.com/playlist?list=PL4QRSQmrCreF3dSp3RokdWmS50o0QNesJ"
|
||||
FILE_NAME_FORMAT: "%(title)s;%(uploader)s"
|
||||
#deploy:
|
||||
#resources:
|
||||
#limits:
|
||||
#cpus: '0.005'
|
||||
#memory: 1000M
|
||||
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
apt-get -y update
|
||||
apt-get -y upgrade
|
||||
cp /music/archive.dat /download
|
||||
./yt-dlp -U
|
||||
./yt-dlp -P "/download" --download-archive "/download/archive.dat" --sleep-interval 5 -x -o ${FILE_NAME_FORMAT} --add-metadata --embed-thumbnail --embed-chapters ${PLAYLIST_URL} 2> /error/error.log
|
||||
cp /download/* /music
|
||||
Reference in New Issue
Block a user