-
Notifications
You must be signed in to change notification settings - Fork 600
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
65 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,10 +48,7 @@ func copyAction(cmd *cobra.Command, args []string) error { | |
if err != nil { | ||
return err | ||
} | ||
u, err := osutil.LimaUser(false) | ||
if err != nil { | ||
return err | ||
} | ||
|
||
instDirs := make(map[string]string) | ||
scpFlags := []string{} | ||
scpArgs := []string{} | ||
|
@@ -86,6 +83,10 @@ func copyAction(cmd *cobra.Command, args []string) error { | |
if inst.Status == store.StatusStopped { | ||
return fmt.Errorf("instance %q is stopped, run `limactl start %s` to start the instance", instName, instName) | ||
} | ||
u, err := osutil.LimaUser(false, inst.LimaVersion) | ||
if err != nil { | ||
return err | ||
} | ||
if legacySSH { | ||
scpFlags = append(scpFlags, "-P", fmt.Sprintf("%d", inst.SSHLocalPort)) | ||
scpArgs = append(scpArgs, fmt.Sprintf("%[email protected]:%s", u.Username, path[1])) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters