51 lines
1.4 KiB
Docker
51 lines
1.4 KiB
Docker
FROM ghcr.io/mwood77/ws4kp-international:latest
|
|
|
|
# Install FFmpeg, Chromium, wget, unzip, and canvas dependencies
|
|
RUN apk add --no-cache \
|
|
chromium \
|
|
ffmpeg \
|
|
font-noto-emoji \
|
|
wget \
|
|
unzip \
|
|
cairo-dev \
|
|
jpeg-dev \
|
|
pango-dev \
|
|
giflib-dev \
|
|
pixman-dev \
|
|
pangomm-dev \
|
|
libjpeg-turbo-dev \
|
|
freetype-dev \
|
|
build-base \
|
|
g++ \
|
|
make \
|
|
python3
|
|
|
|
# Download and extract Weatherscan music
|
|
RUN mkdir -p /music && \
|
|
echo "Downloading Weatherscan music..." && \
|
|
wget -O /tmp/weatherscan.zip "https://archive.org/compress/weatherscancompletecollection/formats=OGG%20VORBIS&file=/weatherscancompletecollection.zip" && \
|
|
echo "Extracting OGG files..." && \
|
|
unzip -j /tmp/weatherscan.zip "*.ogg" -d /music && \
|
|
echo "Music files extracted: $(ls -1 /music/*.ogg | wc -l) files" && \
|
|
rm /tmp/weatherscan.zip && \
|
|
echo "Weatherscan music setup complete!"
|
|
|
|
# Set Puppeteer to use installed Chromium
|
|
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true \
|
|
PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser \
|
|
WS4KP_PORT=8080 \
|
|
MUSIC_PATH=/music
|
|
|
|
# Install our streaming app
|
|
WORKDIR /streaming-app
|
|
COPY package.json yarn.lock* ./
|
|
RUN npm install -g yarn && yarn install --frozen-lockfile || yarn install
|
|
COPY index.js ./
|
|
COPY src/ ./src/
|
|
|
|
# Expose both ports
|
|
EXPOSE 3000 8080
|
|
|
|
# Start both services
|
|
CMD cd /app && node index.js & cd /streaming-app && yarn start
|