34 lines
989 B
Docker
34 lines
989 B
Docker
FROM ghcr.io/mwood77/ws4kp-international:latest
|
|
|
|
# Install FFmpeg, Chromium, wget, and unzip
|
|
RUN apk add --no-cache \
|
|
chromium \
|
|
ffmpeg \
|
|
font-noto-emoji \
|
|
wget \
|
|
unzip
|
|
|
|
# Download and extract Weatherscan music
|
|
RUN mkdir -p /music && \
|
|
wget -O /tmp/weatherscan.zip "https://archive.org/compress/weatherscancompletecollection/formats=OGG%20VORBIS&file=/weatherscancompletecollection.zip" && \
|
|
unzip -j /tmp/weatherscan.zip "*.ogg" -d /music && \
|
|
rm /tmp/weatherscan.zip
|
|
|
|
# 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 ./
|
|
|
|
# Expose both ports
|
|
EXPOSE 3000 8080
|
|
|
|
# Start both services
|
|
CMD cd /app && node index.js & cd /streaming-app && yarn start
|