Files
n8n-ffmpeg-proxy/Dockerfile
drholy 5ca4ceb1cf
All checks were successful
Build, Push and Redeploy Docker Image / build-and-push (push) Successful in 5m54s
Обновить Dockerfile
2026-08-30 15:11:14 +07:00

52 lines
1.0 KiB
Docker

FROM node:24-alpine3.22
ARG N8N_VERSION=latest
ARG SOCKS_IP=192.168.31.240
ENV NODE_OPTIONS=--no-node-snapshot
RUN apk add --no-cache \
ffmpeg \
curl \
wget \
iptables \
redsocks \
gnupg \
netcat-openbsd \
su-exec \
&& apk add --no-cache --virtual .build-deps \
python3 \
make \
g++ \
&& npm install --global "n8n@${N8N_VERSION}" \
&& apk del .build-deps \
&& npm cache clean --force
RUN mkdir -p /home/node/.n8n \
&& chown -R node:node /home/node
COPY start-n8n.sh /start.sh
RUN chmod +x /start.sh
RUN printf '%s\n' \
"base {" \
" log_debug = off;" \
" log_info = on;" \
" log = stderr;" \
" daemon = off;" \
" redirector = iptables;" \
"}" \
"redsocks {" \
" local_ip = 127.0.0.1;" \
" local_port = 12345;" \
" ip = ${SOCKS_IP};" \
" port = 1080;" \
" type = socks5;" \
"}" \
> /etc/redsocks.conf
WORKDIR /home/node
EXPOSE 5678
ENTRYPOINT ["/start.sh"]