@@ -320,7 +320,8 @@ func (c *Connection) Healthcheck() ([]byte, error) {
320320 }
321321
322322 if cmd == "host" {
323- return nil , errors .New (L ("healthcheck not supported on host" ))
323+ // Healthcheck not supported on host, always return nil
324+ return nil , nil
324325 }
325326
326327 cmdArgs := []string {"healthcheck" , "run" , c .podName }
@@ -399,7 +400,7 @@ func (c *Connection) Copy(src string, dst string, user string, group string) err
399400 }
400401
401402 srcPath := strings .Replace (src , "server:" , "" , 1 )
402- // Assume the same name as the source if we use copy with just "server:""
403+ // Assume the same name as the source if we use copy with just "server:"
403404 // Similarly if we copy to the directory "something/"
404405 if strings .HasSuffix (dst , ":" ) || strings .HasSuffix (dst , "/" ) {
405406 dst += filepath .Base (srcPath )
@@ -448,7 +449,7 @@ func (c *Connection) Copy(src string, dst string, user string, group string) err
448449 if command == "kubectl" {
449450 execArgs = append (execArgs , "-n" , namespace )
450451 }
451- if command == "host" {
452+ if c . backend == "host" {
452453 execArgs = []string {owner , dstPath }
453454 command = "chown"
454455 } else {
0 commit comments