Skip to content

Commit

Permalink
docs: optionalInteger|String|Duration (#8729)
Browse files Browse the repository at this point in the history
  • Loading branch information
lidel committed Feb 10, 2022
1 parent a93907a commit f9643a6
Showing 1 changed file with 23 additions and 3 deletions.
26 changes: 23 additions & 3 deletions docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ config file at runtime.
- [`strings`](#strings)
- [`duration`](#duration)
- [`optionalInteger`](#optionalinteger)
- [`optionalString`](#optionalstring)
- [`optionalDuration`](#optionalduration)
- [`Addresses`](#addresses)
- [`Addresses.API`](#addressesapi)
- [`Addresses.Gateway`](#addressesgateway)
Expand Down Expand Up @@ -270,12 +272,30 @@ does (e.g, `"1d2h4m40.01s"`).

### `optionalInteger`

Optional Integers allow specifying some numerical value which has
an implicit default when `null` or missing from the config file:
Optional integers allow specifying some numerical value which has
an implicit default when missing from the config file:

- `null`/missing (apply the default value defined in go-ipfs sources)
- `null`/missing will apply the default value defined in go-ipfs sources (`.WithDefault(value)`)
- an integer between `-2^63` and `2^63-1` (i.e. `-9223372036854775808` to `9223372036854775807`)


### `optionalString`

Optional strings allow specifying some string value which has
an implicit default when missing from the config file:

- `null`/missing will apply the default value defined in go-ipfs sources (`.WithDefault("value")`)
- a string


### `optionalDuration`

Optional durations allow specifying some duration value which has
an implicit default when missing from the config file:

- `null`/missing will apply the default value defined in go-ipfs sources (`.WithDefault("1h2m3s")`)
- a string with a valid [go duration](#duration) (e.g, `"1d2h4m40.01s"`).

## `Addresses`

Contains information about various listener addresses to be used by this node.
Expand Down

0 comments on commit f9643a6

Please sign in to comment.