mirror of
https://github.com/semaphoreui/semaphore.git
synced 2024-11-23 20:35:24 +01:00
fix(be): SSH connecting with wrong username https://github.com/semaphoreui/semaphore/issues/1964
This commit is contained in:
parent
eed4586af1
commit
85f7d75720
@ -130,6 +130,7 @@ func (key *AccessKey) Install(usage AccessKeyRole, logger task_logger.Logger) (i
|
|||||||
var agent ssh.Agent
|
var agent ssh.Agent
|
||||||
agent, err = key.startSSHAgent(logger)
|
agent, err = key.startSSHAgent(logger)
|
||||||
installation.SSHAgent = &agent
|
installation.SSHAgent = &agent
|
||||||
|
installation.Login = key.SshKey.Login
|
||||||
}
|
}
|
||||||
case AccessKeyRoleAnsiblePasswordVault:
|
case AccessKeyRoleAnsiblePasswordVault:
|
||||||
if key.Type != AccessKeyLoginPassword {
|
if key.Type != AccessKeyLoginPassword {
|
||||||
@ -148,7 +149,7 @@ func (key *AccessKey) Install(usage AccessKeyRole, logger task_logger.Logger) (i
|
|||||||
var agent ssh.Agent
|
var agent ssh.Agent
|
||||||
agent, err = key.startSSHAgent(logger)
|
agent, err = key.startSSHAgent(logger)
|
||||||
installation.SSHAgent = &agent
|
installation.SSHAgent = &agent
|
||||||
installation.Login = key.LoginPassword.Login
|
installation.Login = key.SshKey.Login
|
||||||
case AccessKeyLoginPassword:
|
case AccessKeyLoginPassword:
|
||||||
installation.Login = key.LoginPassword.Login
|
installation.Login = key.LoginPassword.Login
|
||||||
installation.Password = key.LoginPassword.Password
|
installation.Password = key.LoginPassword.Password
|
||||||
|
Loading…
Reference in New Issue
Block a user