mirror of
https://github.com/gocsaf/csaf.git
synced 2025-12-22 11:55:40 +01:00
add setup options to provider docs
* Add a first description of the config options for csaf_provider.
* Change option name from `domain` to `canonical_prefix_url`
to make the usage more intuitively. Use`https` in the default,
if unset.
resolve #32
Co-authored-by: Bernhard E. Reiter <bernhard@intevation.de>
Co-authored-by: tschmidtb51 <65305130+tschmidtb51@users.noreply.github.com>
This commit is contained in:
parent
4fae2ec627
commit
5e1f2092e8
5 changed files with 47 additions and 14 deletions
|
|
@ -39,7 +39,7 @@ type config struct {
|
|||
TLPs []tlp `toml:"tlps"`
|
||||
UploadSignature bool `toml:"upload_signature"`
|
||||
OpenPGPURL string `toml:"openpgp_url"`
|
||||
Domain string `toml:"domain"`
|
||||
CanonicalURLPrefix string `toml:"canonical_url_prefix"`
|
||||
NoPassphrase bool `toml:"no_passphrase"`
|
||||
NoValidation bool `toml:"no_validation"`
|
||||
NoWebUI bool `toml:"no_web_ui"`
|
||||
|
|
@ -148,8 +148,8 @@ func loadConfig() (*config, error) {
|
|||
cfg.Web = defaultWeb
|
||||
}
|
||||
|
||||
if cfg.Domain == "" {
|
||||
cfg.Domain = "http://" + os.Getenv("SERVER_NAME")
|
||||
if cfg.CanonicalURLPrefix == "" {
|
||||
cfg.CanonicalURLPrefix = "https://" + os.Getenv("SERVER_NAME")
|
||||
}
|
||||
|
||||
if cfg.TLPs == nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue