aboutsummaryrefslogtreecommitdiffhomepage
path: root/support/doc/docker.md
diff options
context:
space:
mode:
authorFlorent Poinsaut <florent@poinsaut.fr>2018-06-02 08:36:49 +0200
committerChocobozzz <me@florianbigard.com>2018-06-05 08:47:01 +0200
commitf83e339b82b00faeb61ee8bebf720fbaebc367a6 (patch)
tree14b258c34dc2aa8bf5774a30938084ed8134d492 /support/doc/docker.md
parentf8b447538643759217bb25559ac334378ce5ca82 (diff)
downloadPeerTube-f83e339b82b00faeb61ee8bebf720fbaebc367a6.tar.gz
PeerTube-f83e339b82b00faeb61ee8bebf720fbaebc367a6.tar.zst
PeerTube-f83e339b82b00faeb61ee8bebf720fbaebc367a6.zip
Environment variables for Docker Compose
Diffstat (limited to 'support/doc/docker.md')
-rw-r--r--support/doc/docker.md29
1 files changed, 17 insertions, 12 deletions
diff --git a/support/doc/docker.md b/support/doc/docker.md
index 7f3311827..1485e7e85 100644
--- a/support/doc/docker.md
+++ b/support/doc/docker.md
@@ -12,37 +12,42 @@ PeerTube needs a PostgreSQL and a Redis instance to work correctly. If you want
12to quickly set up a full environment, either for trying the service or in 12to quickly set up a full environment, either for trying the service or in
13production, you can use a `docker-compose` setup. 13production, you can use a `docker-compose` setup.
14 14
15```bash 15```shell
16$ cd /your/peertube/directory 16$ cd /your/peertube/directory
17$ mkdir ./docker-volume && mkdir ./docker-volume/traefik 17$ mkdir ./docker-volume && mkdir ./docker-volume/traefik
18$ curl "https://raw.githubusercontent.com/chocobozzz/PeerTube/master/support/docker/production/config/traefik.toml" > ./docker-volume/traefik/traefik.toml 18$ curl "https://raw.githubusercontent.com/chocobozzz/PeerTube/master/support/docker/production/config/traefik.toml" > ./docker-volume/traefik/traefik.toml
19$ touch ./docker-volume/traefik/acme.json && chmod 600 ./docker-volume/traefik/acme.json 19$ touch ./docker-volume/traefik/acme.json && chmod 600 ./docker-volume/traefik/acme.json
20$ curl -s "https://raw.githubusercontent.com/chocobozzz/PeerTube/master/support/docker/production/docker-compose.yml" > ./docker-compose.yml 20$ curl -s "https://raw.githubusercontent.com/chocobozzz/PeerTube/master/support/docker/production/docker-compose.yml" -o docker-compose.yml "https://raw.githubusercontent.com/Chocobozzz/PeerTube/master/support/docker/production/.env" -o .env
21``` 21```
22 22
23Update the reverse proxy configuration: 23Update the reverse proxy configuration:
24 24
25``` 25```shell
26$ vim ./docker-volume/traefik/traefik.toml 26$ vim ./docker-volume/traefik/traefik.toml
27``` 27```
28 28
29Tweak the `docker-compose.yml` file there according to your needs: 29Tweak the `docker-compose.yml` file there according to your needs:
30 30
31``` 31```shell
32$ vim ./docker-compose.yaml 32$ vim ./docker-compose.yaml
33``` 33```
34 34
35You can use the regular `up` command to set it up, with possible overrides of 35Then tweak the `.env` file to change the enviromnent variables:
36the environment variables:
37 36
38```bash 37```shell
39$ PEERTUBE_WEBSERVER_HOSTNAME="domain.tld" docker-compose up 38$ vim ./.env
40``` 39```
41 40
42Other environment variables are used in 41Other environment variables are used in
43`support/docker/production/config/custom-environment-variables.yaml` and can be 42`support/docker/production/config/custom-environment-variables.yaml` and can be
44intuited from usage. 43intuited from usage.
45 44
45You can use the regular `up` command to set it up:
46
47```shell
48$ docker-compose up
49```
50
46**Important**: note that you'll get the initial `root` user password from the 51**Important**: note that you'll get the initial `root` user password from the
47program output, so check out your logs to find them. 52program output, so check out your logs to find them.
48 53
@@ -50,17 +55,17 @@ program output, so check out your logs to find them.
50 55
51Pull the latest images and rerun PeerTube: 56Pull the latest images and rerun PeerTube:
52 57
53``` 58```shell
54$ cd /your/peertube/directory 59$ cd /your/peertube/directory
55$ docker-compose down 60$ docker-compose down
56$ docker-compose pull 61$ docker-compose pull
57$ PEERTUBE_WEBSERVER_HOSTNAME="domain.tld" docker-compose up -d 62$ docker-compose up -d
58``` 63```
59 64
60 65
61## Build your own Docker image 66## Build your own Docker image
62 67
63```bash 68```shell
64$ git clone https://github.com/chocobozzz/PeerTube /tmp/peertube 69$ git clone https://github.com/chocobozzz/PeerTube /tmp/peertube
65$ cd /tmp/peertube 70$ cd /tmp/peertube
66$ docker build . -f ./support/docker/production/Dockerfile.stretch 71$ docker build . -f ./support/docker/production/Dockerfile.stretch
@@ -69,4 +74,4 @@ $ docker build . -f ./support/docker/production/Dockerfile.stretch
69## Development 74## Development
70 75
71We don't have a Docker image for development. See [the CONTRIBUTING guide](https://github.com/Chocobozzz/PeerTube/blob/develop/.github/CONTRIBUTING.md#develop) 76We don't have a Docker image for development. See [the CONTRIBUTING guide](https://github.com/Chocobozzz/PeerTube/blob/develop/.github/CONTRIBUTING.md#develop)
72for more information on how you can hack PeerTube! \ No newline at end of file 77for more information on how you can hack PeerTube!