Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1diff --git a/internal/config/config.go b/internal/config/config.go 2index 36f8625..72ede08 100644 3--- a/internal/config/config.go 4+++ b/internal/config/config.go 5@@ -12,7 +12,7 @@ import ( 6 ) 7 8 const ( 9- configFile = "config.yml" 10+ configFile = "shell-config.yml" 11 defaultSecretFileName = ".gitlab_shell_secret" 12 ) 13 14@@ -91,7 +91,7 @@ func (c *Config) GetHttpClient() *client.HttpClient { 15 // NewFromDirExternal returns a new config from a given root dir. It also applies defaults appropriate for 16 // gitlab-shell running in an external SSH server. 17 func NewFromDirExternal(dir string) (*Config, error) { 18- cfg, err := newFromFile(filepath.Join(dir, configFile)) 19+ cfg, err := newFromFile(filepath.Join("/run/gitlab", configFile)) 20 if err != nil { 21 return nil, err 22 } 23diff --git a/internal/keyline/key_line.go b/internal/keyline/key_line.go 24index c6f2422..fb0426b 100644 25--- a/internal/keyline/key_line.go 26+++ b/internal/keyline/key_line.go 27@@ -37,7 +37,7 @@ func NewPrincipalKeyLine(keyId, principal string, config *config.Config) (*KeyLi 28 } 29 30 func (k *KeyLine) ToString() string { 31- command := fmt.Sprintf("%s %s-%s", path.Join(k.Config.RootDir, executable.BinDir, executable.GitlabShell), k.Prefix, k.ID) 32+ command := fmt.Sprintf("%s %s-%s", path.Join("/run/current-system/sw/bin", executable.GitlabShell), k.Prefix, k.ID) 33 34 return fmt.Sprintf(`command="%s",%s %s`, command, SshOptions, k.Value) 35 } 36diff --git a/support/gitlab_config.rb b/support/gitlab_config.rb 37index 52ac5ee..d96baa3 100644 38--- a/support/gitlab_config.rb 39+++ b/support/gitlab_config.rb 40@@ -7,7 +7,7 @@ class GitlabConfig 41 attr_reader :config 42 43 def initialize 44- @config = YAML.load_file(File.join(ROOT_PATH, 'config.yml')) 45+ @config = YAML.load_file('/run/gitlab/shell-config.yml') 46 end 47 48 def auth_file