Skip to content

Commit a6be5b0

Browse files
Merge pull request #21421 from gordonmessmer/ssh-hostname
Fix SSH Host argument in tag command during scp.
2 parents c41c30b + f8e1ea4 commit a6be5b0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pkg/domain/utils/scp.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ func LoadToRemote(dest entities.ImageScpOptions, localFile string, tag string, u
238238
outArr := strings.Split(rep, " ")
239239
id := outArr[len(outArr)-1]
240240
if len(dest.Tag) > 0 { // tag the remote image using the output ID
241-
_, err := ssh.Exec(&ssh.ConnectionExecOptions{Host: url.Hostname(), Identity: iden, Port: port, User: url.User, Args: []string{"podman", "image", "tag", id, dest.Tag}}, sshEngine)
241+
_, err := ssh.Exec(&ssh.ConnectionExecOptions{Host: url.String(), Identity: iden, Port: port, User: url.User, Args: []string{"podman", "image", "tag", id, dest.Tag}}, sshEngine)
242242
if err != nil {
243243
return "", "", err
244244
}

0 commit comments

Comments
 (0)