Skip to content

Commit

Permalink
Add force-security options to supervisor (#285)
Browse files Browse the repository at this point in the history
  • Loading branch information
pvizeli authored Mar 24, 2021
1 parent 3333f87 commit aa74307
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/supervisor_options.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ Supervisor running on your Home Assistant system.`,
"debug-block",
"diagnostics",
"content-trust",
"force-security",
} {
data, err := cmd.Flags().GetBool(value)
if err == nil && cmd.Flags().Changed(value) {
Expand Down Expand Up @@ -81,12 +82,14 @@ func init() {
supervisorOptionsCmd.Flags().StringP("logging", "l", "", "Logging: debug|info|warning|error|critical")
supervisorOptionsCmd.Flags().IntP("wait-boot", "w", 0, "Seconds to wait after boot")
supervisorOptionsCmd.Flags().BoolP("content-trust", "", true, "Enable/Disable content-trust on the backend")
supervisorOptionsCmd.Flags().BoolP("force-security", "", false, "Enable/Disable force-security on the backend")
supervisorOptionsCmd.Flags().BoolP("debug", "", false, "Enable debug mode")
supervisorOptionsCmd.Flags().BoolP("debug-block", "", false, "Enable debug mode with blocking startup")
supervisorOptionsCmd.Flags().BoolP("diagnostics", "", false, "Enable diagnostics mode")
supervisorOptionsCmd.Flags().StringArrayP("repositories", "r", []string{}, "repositories to track, can be supplied multiple times")

supervisorOptionsCmd.Flags().Lookup("content-trust").NoOptDefVal = "true"
supervisorOptionsCmd.Flags().Lookup("force-security").NoOptDefVal = "false"
supervisorOptionsCmd.Flags().Lookup("debug").NoOptDefVal = "false"
supervisorOptionsCmd.Flags().Lookup("debug-block").NoOptDefVal = "false"
supervisorOptionsCmd.Flags().Lookup("diagnostics").NoOptDefVal = "false"
Expand Down

0 comments on commit aa74307

Please sign in to comment.