Closed laduke closed 2 years ago
I have a json config that works:
{ "domain": "tarv.xyz", "token": "/etc/zeronsd/token", "hosts": "/etc/zeronsd/hosts", "wildcard": true }
If I convert that to toml through some website that does json to toml:
domain = "tarv.xyz" token = "/etc/zeronsd/token" hosts = "/etc/zeronsd/hosts" wildcard = false
I get an error: [2022-02-22T22:26:05Z ERROR zeronsd::cli] invalid type: string "domain = \"tarv.xyz\" token = \"/etc/zeronsd/token\" hosts = \"/etc/zeronsd/hosts\" wildcard = false", expected struct Launcher at line 1 column 1
[2022-02-22T22:26:05Z ERROR zeronsd::cli] invalid type: string "domain = \"tarv.xyz\" token = \"/etc/zeronsd/token\" hosts = \"/etc/zeronsd/hosts\" wildcard = false", expected struct Launcher at line 1 column 1
Edit:
Oh sorry! with --config-type=toml, it works.
--config-type=toml
It seems detect json and yaml automatically without using that flag.
that's because JSON is also valid YAML (honest; look it up). Closing this one as invalid. Ha!
that's because JSON is also valid YAML (honest; look it up).
good grief!
I have a json config that works:
{ "domain": "tarv.xyz", "token": "/etc/zeronsd/token", "hosts": "/etc/zeronsd/hosts", "wildcard": true }
If I convert that to toml through some website that does json to toml:
I get an error:
[2022-02-22T22:26:05Z ERROR zeronsd::cli] invalid type: string "domain = \"tarv.xyz\" token = \"/etc/zeronsd/token\" hosts = \"/etc/zeronsd/hosts\" wildcard = false", expected struct Launcher at line 1 column 1
Edit:
Oh sorry! with
--config-type=toml
, it works.It seems detect json and yaml automatically without using that flag.