aboutsummaryrefslogtreecommitdiffhomepage
path: root/support/docker/janitor/Dockerfile
blob: 5e7970d17ffa5c41083c33396a9bb607efd4f44b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM janitortechnology/ubuntu-dev

# Install PeerTube's dependencies.
# Packages are from https://github.com/Chocobozzz/PeerTube#dependencies
RUN sudo apt-get update -q && sudo apt-get install -qy \
 ffmpeg \
 postgresql \
 openssl

# Download PeerTube's source code.
RUN git clone -b develop https://github.com/Chocobozzz/PeerTube /home/user/PeerTube
WORKDIR /home/user/PeerTube

# Configure the IDEs to use Janitor's source directory as workspace.
ENV WORKSPACE /home/user/PeerTube/

# Install dependencies.
RUN yarn install --pure-lockfile

# Configure Janitor for PeerTube.
COPY --chown=user:user janitor.json /home/user/

# Configure and build PeerTube.
COPY create_user.sql /tmp/
RUN sudo service postgresql start \
 && sudo -u postgres psql --file=/tmp/create_user.sql \
 && npm run build

COPY --chown=user:user supervisord.conf /tmp/supervisord-extra.conf
RUN cat /tmp/supervisord-extra.conf | sudo tee -a /etc/supervisord.conf

# Expose frontend, API and RTMP
EXPOSE 3000 9000 1935