Merge pull request #295 from mozilla/envvar
renamed environment variables to remove P2P_ prefix
This commit is contained in:
commit
5db8a20b9d
3 changed files with 19 additions and 9 deletions
|
@ -7,6 +7,6 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- "1443:1443"
|
- "1443:1443"
|
||||||
environment:
|
environment:
|
||||||
- P2P_REDIS_HOST=redis
|
- REDIS_HOST=redis
|
||||||
redis:
|
redis:
|
||||||
image: redis:alpine
|
image: redis:alpine
|
||||||
|
|
|
@ -3,12 +3,22 @@
|
||||||
| Name | Description
|
| Name | Description
|
||||||
|------------------|-------------|
|
|------------------|-------------|
|
||||||
| `PORT` | Port the server will listen on (defaults to 1443).
|
| `PORT` | Port the server will listen on (defaults to 1443).
|
||||||
| `P2P_S3_BUCKET` | The S3 bucket name.
|
| `S3_BUCKET` | The S3 bucket name.
|
||||||
| `P2P_REDIS_HOST` | Host name of the Redis server.
|
| `REDIS_HOST` | Host name of the Redis server.
|
||||||
|
| `GOOGLE_ANALYTICS_ID` | Google Analytics ID
|
||||||
|
| `SENTRY_CLIENT` | Sentry Client ID
|
||||||
|
| `SENTRY_DSN` | Sentry DSN
|
||||||
|
| `MAX_FILE_SIZE` | in bytes (defaults to 2147483648)
|
||||||
| `NODE_ENV` | "production"
|
| `NODE_ENV` | "production"
|
||||||
|
|
||||||
## Example:
|
## Example:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
$ docker run --net=host -e 'NODE_ENV=production' -e 'P2P_S3_BUCKET=testpilot-p2p-dev' -e 'P2P_REDIS_HOST=dyf9s2r4vo3.bolxr4.0001.usw2.cache.amazonaws.com' mozilla/send:latest
|
$ docker run --net=host -e 'NODE_ENV=production' \
|
||||||
|
-e 'S3_BUCKET=testpilot-p2p-dev' \
|
||||||
|
-e 'REDIS_HOST=dyf9s2r4vo3.bolxr4.0001.usw2.cache.amazonaws.com' \
|
||||||
|
-e 'GOOGLE_ANALYTICS_ID=UA-35433268-78' \
|
||||||
|
-e 'SENTRY_CLIENT=https://51e23d7263e348a7a3b90a5357c61cb2@sentry.prod.mozaws.net/168' \
|
||||||
|
-e 'SENTRY_DSN=https://51e23d7263e348a7a3b90a5357c61cb2:65e23d7263e348a7a3b90a5357c61c44@sentry.prod.mozaws.net/168' \
|
||||||
|
mozilla/send:latest
|
||||||
```
|
```
|
||||||
|
|
|
@ -4,12 +4,12 @@ const conf = convict({
|
||||||
s3_bucket: {
|
s3_bucket: {
|
||||||
format: String,
|
format: String,
|
||||||
default: '',
|
default: '',
|
||||||
env: 'P2P_S3_BUCKET'
|
env: 'S3_BUCKET'
|
||||||
},
|
},
|
||||||
redis_host: {
|
redis_host: {
|
||||||
format: String,
|
format: String,
|
||||||
default: 'localhost',
|
default: 'localhost',
|
||||||
env: 'P2P_REDIS_HOST'
|
env: 'REDIS_HOST'
|
||||||
},
|
},
|
||||||
listen_port: {
|
listen_port: {
|
||||||
format: 'port',
|
format: 'port',
|
||||||
|
@ -25,12 +25,12 @@ const conf = convict({
|
||||||
sentry_id: {
|
sentry_id: {
|
||||||
format: String,
|
format: String,
|
||||||
default: '',
|
default: '',
|
||||||
env: 'P2P_SENTRY_CLIENT'
|
env: 'SENTRY_CLIENT'
|
||||||
},
|
},
|
||||||
sentry_dsn: {
|
sentry_dsn: {
|
||||||
format: String,
|
format: String,
|
||||||
default: '',
|
default: '',
|
||||||
env: 'P2P_SENTRY_DSN'
|
env: 'SENTRY_DSN'
|
||||||
},
|
},
|
||||||
env: {
|
env: {
|
||||||
format: ['production', 'development', 'test'],
|
format: ['production', 'development', 'test'],
|
||||||
|
@ -40,7 +40,7 @@ const conf = convict({
|
||||||
max_file_size: {
|
max_file_size: {
|
||||||
format: Number,
|
format: Number,
|
||||||
default: 1024 * 1024 * 1024 * 2,
|
default: 1024 * 1024 * 1024 * 2,
|
||||||
env: 'P2P_MAX_FILE_SIZE'
|
env: 'MAX_FILE_SIZE'
|
||||||
},
|
},
|
||||||
expire_seconds: {
|
expire_seconds: {
|
||||||
format: Number,
|
format: Number,
|
||||||
|
|
Loading…
Reference in a new issue