Browse Source

minor fixes

env-vars-docs-#90
rozetko 2 years ago
parent
commit
8e4b29508b
  1. 6
      README.md

6
README.md

@ -23,11 +23,11 @@ Hastic can be configured using config-file or environment variables.
At first, choose which datasource you'll be using: `prometheus` or `influx`. Only one can be used at a time. At first, choose which datasource you'll be using: `prometheus` or `influx`. Only one can be used at a time.
#### Config-file #### Config-file
- copy the config example to the release directory - copy the config example to the release directory:
```bash ```bash
cp config.example.toml release/config.toml cp config.example.toml release/config.toml
``` ```
- edit the config file, e.g. using `nano` - edit the config file, e.g. using `nano`:
```bash ```bash
nano release/config.toml nano release/config.toml
``` ```
@ -46,7 +46,7 @@ export HASTIC_PROMETHEUS__URL=http://localhost:9090
export HASTIC_PROMETHEUS__QUERY=rate(go_memstats_alloc_bytes_total[5m]) export HASTIC_PROMETHEUS__QUERY=rate(go_memstats_alloc_bytes_total[5m])
``` ```
or specifing them in a run command (they'll be actual only for one run) or specifing them in a run command (they'll be actual only for one run):
```bash ```bash
HASTIC_PORT=8000 HASTIC_PROMETHEUS__URL=http://localhost:9090 HASTIC_PROMETHEUS__QUERY=rate(go_memstats_alloc_bytes_total[5m]) ./release/hastic HASTIC_PORT=8000 HASTIC_PROMETHEUS__URL=http://localhost:9090 HASTIC_PROMETHEUS__QUERY=rate(go_memstats_alloc_bytes_total[5m]) ./release/hastic
``` ```

Loading…
Cancel
Save