Skip to content

Commit 0a2a992

Browse files
committed
adjust ignore location
1 parent 6289408 commit 0a2a992

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/setting/setting.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ func forcePathSeparator(path string) {
136136
// This check is ignored under Windows since SSH remote login is not the main
137137
// method to login on Windows.
138138
func IsRunUserMatchCurrentUser(runUser string) (string, bool) {
139-
if IsWindows || SSH.StartBuiltinServer || ignoreCheckRunUser {
139+
if IsWindows || SSH.StartBuiltinServer {
140140
return "", true
141141
}
142142

@@ -260,7 +260,7 @@ func loadRunModeFrom(rootCfg ConfigProvider) {
260260
IsProd = strings.EqualFold(RunMode, "prod")
261261
// Does not check run user when the install lock is off.
262262
installLock := rootCfg.Section("security").Key("INSTALL_LOCK").MustBool(false)
263-
if installLock {
263+
if installLock && !ignoreCheckRunUser {
264264
currentUser, match := IsRunUserMatchCurrentUser(RunUser)
265265
if !match {
266266
log.Fatal("Expect user '%s' but current user is: %s", RunUser, currentUser)

0 commit comments

Comments
 (0)