mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-22 16:36:30 +00:00
make WOODPECKER_MIGRATIONS_ALLOW_LONG have an actuall effect (#2251)
close #2079 as we sett the global vars **after** migrations we did never had a chance to propagate a **true** in WOODPECKER_MIGRATIONS_ALLOW_LONG to the migrations ... --------- Co-authored-by: qwerty287 <80460567+qwerty287@users.noreply.github.com>
This commit is contained in:
parent
35baaa8224
commit
350282ce29
2 changed files with 2 additions and 1 deletions
|
@ -354,7 +354,6 @@ func setupEvilGlobals(c *cli.Context, v store.Store, f forge.Forge) {
|
|||
server.Config.Pipeline.Networks = c.StringSlice("network")
|
||||
server.Config.Pipeline.Volumes = c.StringSlice("volume")
|
||||
server.Config.Pipeline.Privileged = c.StringSlice("escalate")
|
||||
server.Config.Server.Migrations.AllowLong = c.Bool("migrations-allow-long")
|
||||
server.Config.Server.EnableSwagger = c.Bool("enable-swagger")
|
||||
|
||||
// prometheus
|
||||
|
|
|
@ -52,6 +52,8 @@ import (
|
|||
)
|
||||
|
||||
func setupStore(c *cli.Context) (store.Store, error) {
|
||||
// TODO: find a better way than global var to pass down to allow long migrations
|
||||
server.Config.Server.Migrations.AllowLong = c.Bool("migrations-allow-long")
|
||||
datasource := c.String("datasource")
|
||||
driver := c.String("driver")
|
||||
xorm := store.XORM{
|
||||
|
|
Loading…
Reference in a new issue