peertube-app/Dockerfile

36 lines
1.2 KiB
Docker
Raw Normal View History

2020-06-16 04:47:04 +00:00
FROM cloudron/base:2.0.0@sha256:f9fea80513aa7c92fe2e7bf3978b54c8ac5222f47a9a32a7f8833edf0eb5a4f4
RUN mkdir -p /app/code /app/pkg
WORKDIR /app/code
RUN apt-get -y update && apt -y install ffmpeg && rm -rf /var/cache/apt /var/lib/apt/lists
# install yq
RUN curl -sL https://github.com/mikefarah/yq/releases/download/3.2.1/yq_linux_amd64 -o /usr/bin/yq && \
chmod +x /usr/bin/yq
2020-06-24 19:26:29 +00:00
ARG VERSION=2.2.0
2020-06-16 04:47:04 +00:00
# install peertube
2020-06-24 19:26:29 +00:00
RUN curl -sL https://github.com/Chocobozzz/PeerTube/releases/download/v${VERSION}/peertube-v${VERSION}.tar.xz | tar --strip-components 1 -Jxvf -
RUN yarn install --production --pure-lockfile
# remove the peertube suffix of dbname (see https://github.com/Chocobozzz/PeerTube/pull/2898)
RUN sed -e "s/DBNAME: 'peertube' +/DBNAME: /g" -i dist/server/initializers/config.js
2020-06-16 04:47:04 +00:00
# dbname branch
2020-06-24 19:26:29 +00:00
# ARG VERSION=e7fe135b5a5666147256efa11d15474d761c37d4
# RUN curl -L https://github.com/cloudron-io/PeerTube/archive/${VERSION}.tar.gz | tar -zxvf - --strip-components=1
#
# RUN yarn install && npm run build
2020-06-16 04:47:04 +00:00
RUN ln -sf /app/data/production.yaml /app/code/config/local-production.yaml
COPY production.yaml.example start.sh /app/pkg/
ENV NODE_ENV production
ENV NODE_CONFIG_DIR /app/code/config
CMD [ "/app/pkg/start.sh" ]