Skip to content

Commit

Permalink
disable in UI
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert Wiesner committed May 13, 2023
1 parent 7c7d390 commit 8b8b95e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
9 changes: 5 additions & 4 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,11 @@ func renderIndexHTML(cfg *config.Config) (string, error) {
}

data := map[string]interface{}{
"DisableLoadSecrets": cfg.DisableLoadSecrets,
"WebContext": cfg.Web.Context,
"InitialSecret": initialSecret,
"Version": version.Version,
"DisableLoadSecrets": cfg.DisableLoadSecrets,
"DisableValidateSecrets": cfg.SealedSecrets.CertURL != "",
"WebContext": cfg.Web.Context,
"InitialSecret": initialSecret,
"Version": version.Version,
}

var tpl bytes.Buffer
Expand Down
3 changes: 2 additions & 1 deletion templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
<v-btn @click="dencode" text>Encode / Decode</v-btn>
{{ if eq .DisableLoadSecrets false}}<v-btn @click="loadSecrets" text>Secrets</v-btn>{{end}}
<v-btn @click="seal" text>Seal</v-btn>
<v-btn @click="validate" text>Validate</v-btn>
{{ if eq .DisableValidateSecrets false}}
<v-btn @click="validate" text>Validate</v-btn>{{end}}
</v-app-bar>

<v-main>
Expand Down

0 comments on commit 8b8b95e

Please sign in to comment.