fix: lego v5 = syntax for flags
This commit is contained in:
parent
fbbf1732b3
commit
d144fcdc28
1 changed files with 5 additions and 5 deletions
|
|
@ -164,16 +164,16 @@ func obtainCertsLego(domains []string, email, backupDir, legoDir, legoPath strin
|
|||
return fmt.Errorf("creating lego dir: %w", err)
|
||||
}
|
||||
|
||||
// Build lego args (v5+: flags go after the command)
|
||||
// Build lego args (v5+: flags go after the command, use = syntax)
|
||||
args := []string{"run",
|
||||
"--email", email,
|
||||
"--email=" + email,
|
||||
"--http",
|
||||
"--http.port", ":80",
|
||||
"--path", legoDir,
|
||||
"--http.port=:80",
|
||||
"--path=" + legoDir,
|
||||
"--accept-tos",
|
||||
}
|
||||
for _, d := range domains {
|
||||
args = append(args, "--domains", d)
|
||||
args = append(args, "--domains="+d)
|
||||
}
|
||||
|
||||
cmd := exec.Command(legoPath, args...)
|
||||
|
|
|
|||
Loading…
Reference in a new issue