4 if ! command -v gpg > /dev/null; then \
6 apt-get install -y --no-install-recommends \
10 rm -rf /var/lib/apt/lists/*; \
13 # Install dependencies
15 && apt-get -y install ffmpeg \
16 && rm /var/lib/apt/lists/* -fR
19 RUN groupadd -r peertube \
20 && useradd -r -g peertube -m peertube
22 # grab gosu for easy step-down from root
25 apt-get install -y gosu; \
26 rm -rf /var/lib/apt/lists/*; \
32 RUN chown -R peertube:peertube /app
36 RUN yarn install --pure-lockfile \
38 && rm -r ./node_modules ./client/node_modules \
39 && yarn install --pure-lockfile --production \
44 RUN mkdir /data /config
45 RUN chown -R peertube:peertube /data /config
47 ENV NODE_ENV production
48 ENV NODE_CONFIG_DIR /config
53 COPY ./support/docker/production/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
54 ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]