mirror of
https://github.com/timvisee/send-docker-compose.git
synced 2025-12-07 06:20:54 +03:00
Merge pull request #1 from pirate/patch-2
add configuration section to README explaining common gotchas
This commit is contained in:
48
README.md
48
README.md
@@ -16,13 +16,15 @@ This is configurable in your [`.env`](.env.example) file.
|
|||||||
See [docker-compose.yaml](./docker-compose.yaml).
|
See [docker-compose.yaml](./docker-compose.yaml).
|
||||||
|
|
||||||
### Usage
|
### Usage
|
||||||
- Install Docker with Docker compose
|
|
||||||
- Clone repository
|
1. Install Docker with Docker Compose https://get.docker.com/
|
||||||
- Run `cp .env.example .env` and configure it (see [example](#example-env))
|
2. Clone this repository `git clone https://github.com/timvisee/send-docker-compose`
|
||||||
- Run `docker-compose up`
|
3. Run `cp .env.example .env` and configure it (see [example](#example-env))
|
||||||
- Visit your domain
|
4. Run `docker-compose up`
|
||||||
|
5. Visit your domain
|
||||||
|
|
||||||
### Example .env
|
### Example .env
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Docker image to use for Send
|
# Docker image to use for Send
|
||||||
# - Latest Send version by @timvisee: registry.gitlab.com/timvisee/send:latest
|
# - Latest Send version by @timvisee: registry.gitlab.com/timvisee/send:latest
|
||||||
@@ -41,3 +43,39 @@ LETSENCRYPT_HOST=
|
|||||||
# Optional: for LetsEncrypt SSL, your email address
|
# Optional: for LetsEncrypt SSL, your email address
|
||||||
LETSENCRYPT_EMAIL=mail@example.org
|
LETSENCRYPT_EMAIL=mail@example.org
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Configuration
|
||||||
|
|
||||||
|
All the config options and their defaults can be found here: https://github.com/timvisee/send/blob/master/server/config.js.
|
||||||
|
|
||||||
|
Config options expecting array values (e.g. `EXPIRE_TIMES_SECONDS`, `DOWNLOAD_COUNTS`) are parsed as CSV, and the first entry is the default.
|
||||||
|
|
||||||
|
Other options should be set as unquoted strings, integers, booleans, etc., for example:
|
||||||
|
```yaml
|
||||||
|
...
|
||||||
|
services:
|
||||||
|
...
|
||||||
|
send:
|
||||||
|
...
|
||||||
|
environment:
|
||||||
|
...
|
||||||
|
|
||||||
|
# strings numbers, bools, etc. shoul all be set as bare unquoted values
|
||||||
|
- BASE_URL=https://send.example.com
|
||||||
|
- DHPARAM_GENERATION=false
|
||||||
|
- MAX_DOWNLOADS=250000
|
||||||
|
|
||||||
|
# use values set in the .env using ${VARNAME} bash syntax
|
||||||
|
- VIRTUAL_HOST=${HOST}
|
||||||
|
|
||||||
|
# time values are all in seconds, e.g. 365d * 60*60*24 = 31,536,000 seconds
|
||||||
|
- MAX_EXPIRE_SECONDS=31536000
|
||||||
|
- DEFAULT_EXPIRE_SECONDS=86400
|
||||||
|
|
||||||
|
# array configs are set as CSV (first entry is the default for the UI dropdown)
|
||||||
|
- EXPIRE_TIMES_SECONDS=86400,3600,86400,604800,2592000,31536000,157680000
|
||||||
|
- DOWNLOAD_COUNTS=10,1,2,5,10,15,25,50,100,1000,10000,100000,250000
|
||||||
|
|
||||||
|
# size values are are in bytes, e.g. 10GB * 1024*1024*1024 = 10,747,904,000 bytes
|
||||||
|
- MAX_FILE_SIZE=10747904000
|
||||||
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user