Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
zephyrchien committed Sep 22, 2024
1 parent 3963f80 commit a1af137
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 8 deletions.
2 changes: 1 addition & 1 deletion examples/balance.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"log": {
"level": "warn",
"output": "/var/log/realm.log"
"output": "realm.log"
},
"network": {
"no_tcp": false,
Expand Down
2 changes: 1 addition & 1 deletion examples/balance.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[log]
level = "warn"
output = "/var/log/realm.log"
output = "realm.log"

[network]
no_tcp = false
Expand Down
2 changes: 1 addition & 1 deletion examples/full.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"log": {
"level": "warn",
"output": "/var/log/realm.log"
"output": "realm.log"
},
"dns": {
"mode": "ipv4_only",
Expand Down
2 changes: 1 addition & 1 deletion examples/full.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[log]
level = "warn"
output = "/var/log/realm.log"
output = "realm.log"

[dns]
mode = "ipv4_only"
Expand Down
2 changes: 1 addition & 1 deletion examples/good.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"log": {
"level": "warn",
"output": "/var/log/realm.log"
"output": "realm.log"
},
"network": {
"no_tcp": false,
Expand Down
2 changes: 1 addition & 1 deletion examples/good.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[log]
level = "warn"
output = "/var/log/realm.log"
output = "realm.log"

[network]
no_tcp = false
Expand Down
9 changes: 7 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,14 +164,19 @@ Start from command line arguments:
realm -l 0.0.0.0:5000 -r 1.1.1.1:443
```

Start with a config file:
Start with config file:

```shell
# use toml
realm -c config.toml

# use json
realm -c config.json

# use configs in folder (since v2.6.2)
# all toml and json files are recursively included (e.g.: config/log.toml, config/node/n1.toml)
# hidden ones are recursively excluded (e.g.: config/.hidden_file, config/.hidden_dir/)
realm -c config/
```

Start with environment variables:
Expand All @@ -197,7 +202,7 @@ TOML Example
```toml
[log]
level = "warn"
output = "/var/log/realm.log"
output = "realm.log"

[network]
no_tcp = false
Expand Down

0 comments on commit a1af137

Please sign in to comment.