mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-22 16:36:30 +00:00
Allow configuring the URL to user documentation
This commit is contained in:
parent
f694d6f2e4
commit
943a308afe
3 changed files with 8 additions and 1 deletions
|
@ -118,6 +118,12 @@ var flags = []cli.Flag{
|
|||
Usage: "file path for the drone config",
|
||||
Value: ".drone.yml",
|
||||
},
|
||||
cli.StringFlag{
|
||||
EnvVar: "DRONE_DOCS,WOODPECKER_DOCS",
|
||||
Name: "docs",
|
||||
Usage: "link to user documentation",
|
||||
Value: "https://woodpecker.laszlo.cloud",
|
||||
},
|
||||
cli.DurationFlag{
|
||||
EnvVar: "DRONE_SESSION_EXPIRES,WOODPECKER_SESSION_EXPIRES",
|
||||
Name: "session-expires",
|
||||
|
|
|
@ -203,6 +203,7 @@ func setupTree(c *cli.Context) *httptreemux.ContextMux {
|
|||
web.New(
|
||||
web.WithDir(c.String("www")),
|
||||
web.WithSync(time.Hour*72),
|
||||
web.WithDocs(c.String("docs"))
|
||||
).Register(tree)
|
||||
return tree
|
||||
}
|
||||
|
|
|
@ -172,7 +172,7 @@ const LOGO = (
|
|||
<br />
|
||||
<span>
|
||||
<a
|
||||
href="https://woodpecker.laszlo.cloud"
|
||||
href={window.DRONE_DOCS}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
|
|
Loading…
Reference in a new issue