Skip to content

Commit 2ca2f17

Browse files
committed
Improve docker compose deployment documentation (inovex#4561 )
1 parent 2141774 commit 2ca2f17

File tree

1 file changed

+39
-9
lines changed

1 file changed

+39
-9
lines changed

docs/src/content/docs/self-hosting/docker.md

+39-9
Original file line numberDiff line numberDiff line change
@@ -8,52 +8,82 @@ sidebar:
88
Scrumlr can be deployed using a Docker Compose file. This is the easiest way to get started with Scrumlr.
99
We maintain a Docker Compose file in our Repository that you can use to deploy Scrumlr.
1010

11-
## Prerequisites
11+
# Prerequisites
12+
1213
Clone the Scrumlr repository to your server and navigate to the deployment directory.
14+
1315
```sh
1416
git clone https://github.com/inovex/scrumlr.io
1517
cd scrumlr.io/deployment/docker
1618
```
1719

1820
Copy the `.env.example` file to `.env` and adjust the variables to your needs.
21+
1922
```sh
2023
cp .env.example .env
2124
```
2225

23-
## Generating needed secrets
26+
For a new deployment the mandatory variables to fill out are `POSTGRES_PASSWORD` and `SCRUMLR_PRIVATE_KEY`.
27+
28+
# Generating needed secrets
2429

2530
### Postgres Password
2631

27-
Generate a secure password for the Postgres database.
28-
Make sure to set the `POSTGRES_PASSWORD`variable in your .env file to the generated password.
32+
Make sure to set the `POSTGRES_PASSWORD`variable in your `.env` file to a secure password. For example you can generate a 64 characters long one from the terminal with the following command (if you have `pwgen` installed):
33+
2934
```sh
3035
pwgen -s 64 1
3136
```
37+
3238
### JWT Private Key
39+
3340
We use an ECDSA private key to sign the JWT tokens.
3441
***Make sure to keep this key secure as it can be used to decrypt the tokens and generate new ones, potentially compromising your users' accounts.***
42+
3543
```sh
3644
openssl ecparam -genkey -name secp521r1 -noout -out jwt.key
3745
```
38-
Now we need to encode this key to be able to use it as a string in the .env file.
46+
47+
Now we need to encode this key to be able to use it as a string in the `.env` file:
48+
3949
```sh
4050
cat jwt.key | awk '{printf "%s\\n", $0}'
4151
```
4252

43-
## Deployment
53+
Copy the result of this command and paste it into your `.env` file (with `\n` line breaks included) like this, surrounded with quotes:
54+
55+
```ini
56+
SCRUMLR_PRIVATE_KEY="-----BEGIN EC PRIVATE KEY-----\n...\n-----END EC PRIVATE KEY-----\n"
57+
```
58+
59+
# Deployment
60+
4461
You can now start the deployment using the following command.
62+
4563
```sh
4664
docker-compose up -d
4765
```
4866

67+
After a few seconds you can check with `docker ps --all` to see if all the containers have started up. If one crashed or if there is an issue you can check logs with `docker logs (container name or id)`
68+
4969
## Reverse Proxy
70+
5071
We strongly recommend using a reverse proxy to handle TLS termination and to provide a secure connection to your users.
51-
Scrumlr should work with all major reverse proxies like Nginx, Traefik, or Caddy.
72+
Scrumlr should work with all major reverse proxies like [Nginx](https://nginx.org), [Traefik](https://traefik.io/traefik/) or [Caddy](https://caddyserver.com/docs/quick-starts/reverse-proxy).
5273
We automatically include a caddy deployment in the docker-compose file, which you can use as a reverse proxy.
53-
All you need to do is updating the Caddyfile to include your host domain instead of `0.0.0.0:80`.
54-
If you dont want TLS you can simply keep the specified port.
74+
All you need to do is updating the `Caddyfile` to include your host domain instead of `0.0.0.0:80`.
75+
If you don't want TLS you can simply keep the specified port.
5576
Keep in mind that running Scrumlr without TLS is **not recommended**.
77+
5678
```
5779
your_domain {
5880
}
5981
```
82+
83+
# Troubleshooting
84+
85+
## Scrumlr works fine on my machine, but others get an error when they click on "Start now"
86+
87+
Make sure the `SCRUMLR_SERVER_URL` in the `.env` file uses your external ip address, instead of `localhost` or `127.0.0.1`. You can search "what is my ip" on the internet to find your external ip address.
88+
89+

0 commit comments

Comments
 (0)