summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'cmd')
-rw-r--r--cmd/check/main.go3
-rw-r--r--cmd/gitlab-shell-authorized-keys-check/main.go3
-rw-r--r--cmd/gitlab-shell-authorized-principals-check/main.go3
-rw-r--r--cmd/gitlab-shell/main.go4
4 files changed, 9 insertions, 4 deletions
diff --git a/cmd/check/main.go b/cmd/check/main.go
index b87e87e..fbb520b 100644
--- a/cmd/check/main.go
+++ b/cmd/check/main.go
@@ -9,6 +9,7 @@ import (
"gitlab.com/gitlab-org/gitlab-shell/internal/config"
"gitlab.com/gitlab-org/gitlab-shell/internal/executable"
"gitlab.com/gitlab-org/gitlab-shell/internal/logger"
+ "gitlab.com/gitlab-org/gitlab-shell/internal/sshenv"
)
func main() {
@@ -32,7 +33,7 @@ func main() {
logger.Configure(config)
- cmd, err := command.New(executable, os.Args[1:], config, readWriter)
+ cmd, err := command.New(executable, os.Args[1:], sshenv.Env{}, config, readWriter)
if err != nil {
fmt.Fprintf(readWriter.ErrOut, "%v\n", err)
os.Exit(1)
diff --git a/cmd/gitlab-shell-authorized-keys-check/main.go b/cmd/gitlab-shell-authorized-keys-check/main.go
index ba8ddd8..8746353 100644
--- a/cmd/gitlab-shell-authorized-keys-check/main.go
+++ b/cmd/gitlab-shell-authorized-keys-check/main.go
@@ -10,6 +10,7 @@ import (
"gitlab.com/gitlab-org/gitlab-shell/internal/console"
"gitlab.com/gitlab-org/gitlab-shell/internal/executable"
"gitlab.com/gitlab-org/gitlab-shell/internal/logger"
+ "gitlab.com/gitlab-org/gitlab-shell/internal/sshenv"
)
func main() {
@@ -33,7 +34,7 @@ func main() {
logger.Configure(config)
- cmd, err := command.New(executable, os.Args[1:], config, readWriter)
+ cmd, err := command.New(executable, os.Args[1:], sshenv.Env{}, config, readWriter)
if err != nil {
// For now this could happen if `SSH_CONNECTION` is not set on
// the environment
diff --git a/cmd/gitlab-shell-authorized-principals-check/main.go b/cmd/gitlab-shell-authorized-principals-check/main.go
index 412447d..f14fbde 100644
--- a/cmd/gitlab-shell-authorized-principals-check/main.go
+++ b/cmd/gitlab-shell-authorized-principals-check/main.go
@@ -10,6 +10,7 @@ import (
"gitlab.com/gitlab-org/gitlab-shell/internal/console"
"gitlab.com/gitlab-org/gitlab-shell/internal/executable"
"gitlab.com/gitlab-org/gitlab-shell/internal/logger"
+ "gitlab.com/gitlab-org/gitlab-shell/internal/sshenv"
)
func main() {
@@ -33,7 +34,7 @@ func main() {
logger.Configure(config)
- cmd, err := command.New(executable, os.Args[1:], config, readWriter)
+ cmd, err := command.New(executable, os.Args[1:], sshenv.Env{}, config, readWriter)
if err != nil {
// For now this could happen if `SSH_CONNECTION` is not set on
// the environment
diff --git a/cmd/gitlab-shell/main.go b/cmd/gitlab-shell/main.go
index 4db54f9..8286e66 100644
--- a/cmd/gitlab-shell/main.go
+++ b/cmd/gitlab-shell/main.go
@@ -10,6 +10,7 @@ import (
"gitlab.com/gitlab-org/gitlab-shell/internal/console"
"gitlab.com/gitlab-org/gitlab-shell/internal/executable"
"gitlab.com/gitlab-org/gitlab-shell/internal/logger"
+ "gitlab.com/gitlab-org/gitlab-shell/internal/sshenv"
)
var (
@@ -47,7 +48,8 @@ func main() {
logger.Configure(config)
- cmd, err := command.New(executable, os.Args[1:], config, readWriter)
+ env := sshenv.NewFromEnv()
+ cmd, err := command.New(executable, os.Args[1:], env, config, readWriter)
if err != nil {
// For now this could happen if `SSH_CONNECTION` is not set on
// the environment