cd client || exit -1
-npm run ng -- server --hmr --host localhost --port 3000
+npm run ng -- server --hmr --host 0.0.0.0 --port 3000
# Configure Cloud9 IDE to use PeerTube's source directory as workspace (-w).
RUN sudo sed -i "s/-w \/home\/user/-w \/home\/user\/PeerTube/" /etc/supervisord.conf
+# Install dependencies.
+RUN yarn install --pure-lockfile
+
# Configure Janitor for PeerTube.
ADD janitor.json /home/user/
RUN sudo chown user:user /home/user/janitor.json
# Configure and build PeerTube.
-RUN yarn install \
- && npm run build
+ADD create_user.sql /tmp/
+RUN sudo service postgresql start && \
+ sudo -u postgres psql --file=/tmp/create_user.sql
+
+ADD supervisord.conf /tmp/supervisord-extra.conf
+RUN cat /tmp/supervisord-extra.conf | sudo tee -a /etc/supervisord.conf
+
+EXPOSE 3000 9000
--- /dev/null
+create database peertube_dev;
+create user peertube password 'peertube';
+grant all privileges on database peertube_dev to peertube;
"label": "SSH",
"proxy": "none"
},
+ "3000": {
+ "label": "PeerTube web app",
+ "proxy": "https",
+ "preview": true
+ },
"8088": {
"label": "VNC",
"proxy": "https"
"proxy": "https"
},
"9000": {
- "label": "PeerTube",
- "proxy": "https",
- "preview": true
+ "label": "PeerTube API",
+ "proxy": "https"
}
},
"scripts": {
- "Start PeerTube": "npm start",
+ "Start PeerTube": "npm run dev",
"Build PeerTube": "npm run build",
"Run tests": "npm test",
"Update source code": "git pull --rebase origin",
--- /dev/null
+[program:postgresql]
+user = user
+command = sudo -u postgres /usr/lib/postgresql/9.5/bin/postgres -D /var/lib/postgresql/9.5/main -c config_file=/etc/postgresql/9.5/main/postgresql.conf