]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - .github/CONTRIBUTING.md
98908772891f70861667bddc66de988d9de27976
[github/Chocobozzz/PeerTube.git] / .github / CONTRIBUTING.md
1 # Welcome to the contributing guide for PeerTube
2
3 Interesting in contributing? Awesome :)
4
5 **Quick Links:**
6
7 * [Give your feedback](#give-your-feedback)
8 * [Develop on the Server side](#develop-on-the-server-side)
9 * [Develop on the Client side](#develop-on-the-client-side)
10 * [Get started with development](#get-started-with-development)
11 * [Write documentation](#write-documentation)
12
13
14 ## Give your feedback
15
16 You don't need to know how to code to start contributing to PeerTube! Other
17 contributions are very valuable too, among which: you can test the software and
18 report bugs, you can give feedback on potential bugs, features that you are
19 interested in, user interace, design, decentralized architecture...
20
21
22 ## Development
23
24 ## Develop on the Server side
25
26 The server is a web server developed with
27 [NodeJS](https://nodejs.org)/[Express](http://expressjs.com).
28
29 Newcomer? You can find a documentation of the server code/architecture
30 [here](https://github.com/Chocobozzz/PeerTube/blob/master/support/doc/server/code.md).
31
32 Don't hesitate to talk about features you want to develop by creating an issue
33 before you start working on them :).
34
35
36 ## Develop on the Client side
37
38 The client is a web application developed with
39 [TypeScript](https://www.typescriptlang.org/)/[Angular2](https://angular.io/).
40
41 Newcomer? You can find a documentation of the server code/architecture
42 [here](https://github.com/Chocobozzz/PeerTube/blob/master/support/doc/client/code.md).
43
44
45 ## Get started with development
46
47 In this mode, the server will run requests between instances more quickly, the
48 video durations are limited to a few seconds.
49
50 ### Prerequisites
51
52 First, make sure that you have followed the steps to install the dependencies.
53
54 Then, create a postgres database and user with the values set in the
55 `config/default.yaml` file. For instance, if you do not change the values
56 there, the following commands would create a new database called `peertube_dev`
57 and a postgres user called `peertube` with password `peertube`:
58
59 ```bash
60 # sudo -u postgres createuser -P peertube
61 Enter password for new role: peertube
62 # sudo -u postgres createdb -O peertube peertube_dev
63 ```
64
65 ### Server side
66
67 To develop on the server-side:
68
69 ```bash
70 $ npm run dev:server
71 ```
72
73 Then, the server will listen on `localhost:9000`. When server source files
74 change, these are automatically recompiled and the server will automatically
75 restart.
76
77 ### Client side
78
79 To develop on the client side:
80
81 ```bash
82 $ npm run dev:client
83 ```
84
85 The API will listen on `localhost:9000` and the frontend on `localhost:3000`.
86 Client files are automatically compiled on change, and the web browser will
87 reload them automatically thanks to hot module replacement.
88
89 **Username**: *root* <br/>
90 **Password**: *test*
91
92
93 ## Write documentation
94
95 You can help to write the documentation of the REST API, code, architecture,
96 demonstrations...