mirror of
https://github.com/go-gitea/gitea.git
synced 2025-04-08 17:05:45 +02:00
check ci if default false works in mssql
This commit is contained in:
parent
9f546abc38
commit
b7a31515cc
@ -58,7 +58,7 @@ type ActionRunner struct {
|
||||
// Store labels defined in state file (default: .runner file) of `act_runner`
|
||||
AgentLabels []string `xorm:"TEXT"`
|
||||
// Store if this is a runner that only ever get one single job assigned
|
||||
Ephemeral bool `xorm:"ephemeral"`
|
||||
Ephemeral bool `xorm:"ephemeral NOT NULL DEFAULT false"`
|
||||
|
||||
Created timeutil.TimeStamp `xorm:"created"`
|
||||
Updated timeutil.TimeStamp `xorm:"updated"`
|
||||
|
@ -9,14 +9,8 @@ import (
|
||||
|
||||
func AddEphemeralToActionRunner(x *xorm.Engine) error {
|
||||
type ActionRunner struct {
|
||||
Ephemeral bool `xorm:"ephemeral"`
|
||||
Ephemeral bool `xorm:"ephemeral NOT NULL DEFAULT false"`
|
||||
}
|
||||
|
||||
if err := x.Sync(new(ActionRunner)); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// update all records to set ephemeral to false
|
||||
_, err := x.Exec("UPDATE `action_runner` SET `ephemeral` = false WHERE `ephemeral` IS NULL")
|
||||
return err
|
||||
return x.Sync(new(ActionRunner))
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user