adamant-kite-43734
06/29/2022, 3:27 PMfast-garage-66093
06/29/2022, 4:41 PMlima
as the internal username when the host username is not valid on Linux. This is not an issue and works fine.fast-garage-66093
06/29/2022, 4:42 PMssh
, even though the filename is quoted.white-vegetable-30350
06/29/2022, 4:51 PM/Users/wenmingcao 1/Library/Application Support/rancher-desktop/lima/_config/user
fast-garage-66093
06/29/2022, 4:56 PMsocat
installed on the machine? Or can you install it with brew install socat
?white-vegetable-30350
06/29/2022, 4:56 PMfast-garage-66093
06/29/2022, 4:57 PM$ cd ~/Library/Application\ Support/rancher-desktop/lima/0/
$ socat -,echo=0,icanon=0 unix-connect:serial.sock
root
Welcome to Alpine!
[...]
lima-rancher-desktop:~#
fast-garage-66093
06/29/2022, 4:58 PMsocat
, but it is waiting for a username, so you have to type root
and Enterfast-garage-66093
06/29/2022, 4:59 PMauthorized_keys
file exists (but use lima.linux
instead of jan.linux
):
lima-rancher-desktop:~# ls -la /home/jan.linux/.ssh
total 12
drwx------ 2 jan jan 4096 Jun 29 00:36 .
drwxr-xr-x 4 jan jan 4096 Jun 29 16:48 ..
-rw------- 1 jan jan 92 Jun 29 00:36 authorized_keys
fast-garage-66093
06/29/2022, 5:00 PMwhite-vegetable-30350
06/29/2022, 5:01 PMfast-garage-66093
06/29/2022, 5:01 PMauthorized_keys
should be identical to the user.pub
file on the hostfast-garage-66093
06/29/2022, 5:02 PMlima-rancher-desktop:~# cat /home/jan.linux/.ssh/authorized_keys
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILqESOec8Hf8PFT7Ptz6z9NexbzCsARBXCV6yUNibreG jan@mactop
fast-garage-66093
06/29/2022, 5:02 PM$ cat ~/Library/Application\ Support/rancher-desktop/lima/_config/user.pub
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILqESOec8Hf8PFT7Ptz6z9NexbzCsARBXCV6yUNibreG jan@mactop
white-vegetable-30350
06/29/2022, 5:36 PMlima-rancher-desktop:~# ls -la /home/lima.linux/.ssh
ls: /home/lima.linux/.ssh: No such file or directory
lima-rancher-desktop:~# cd /home
lima-rancher-desktop:/home# ls -al
total 4
drwxr-xr-x 2 root root 4096 Jun 28 17:45 .
drwxr-xr-x 21 root root 420 Jun 28 18:57 ..
lima-rancher-desktop:/home#
fast-garage-66093
06/29/2022, 5:49 PMcat /var/log/lima-init.log
and create a text snippet to attach it here?fast-garage-66093
06/29/2022, 5:49 PMlima-rancher-desktop:~# cat /var/log/lima-init.log
+ export 'LIMA_CIDATA_MNT=/mnt/lima-cidata'
+ '[' --local '!=' --local ]
+ ln -s /var/log/lima-init.log /var/log/cloud-init-output.log
+ LIMA_CIDATA_DEV=/dev/disk/by-label/cidata
+ mkdir -p -m 700 /mnt/lima-cidata
+ mount -o 'ro,mode=0700,dmode=0700,overriderockperm,exec,uid=0' /dev/disk/by-label/cidata /mnt/lima-cidata
+ . /mnt/lima-cidata/lima.env
[...]
fast-garage-66093
06/29/2022, 5:51 PM+ hostname lima-0
+ LIMA_CIDATA_HOMEDIR=/home/jan.linux
+ useradd --home-dir /home/jan.linux --create-home --uid 501 jan
+ echo 'jan ALL=(ALL) NOPASSWD:ALL'
+ LIMA_CIDATA_SSHDIR=/home/jan.linux/.ssh
+ mkdir -p -m 700 /home/jan.linux/.ssh
+ awk '/ssh-authorized-keys/ {flag=1; next} /^ *$/ {flag=0} flag {sub(/^ +- /, ""); gsub("\"", ""); print $0}' /mnt/lima-cidata/user-data
+ id -g jan
+ LIMA_CIDATA_GID=1000
+ chown -R 501:1000 /home/jan.linux/.ssh
+ chmod 600 /home/jan.linux/.ssh/authorized_keys
fast-garage-66093
06/29/2022, 5:56 PMfast-garage-66093
06/29/2022, 5:57 PMwhite-vegetable-30350
06/29/2022, 5:58 PMfast-garage-66093
06/29/2022, 5:58 PMwhite-vegetable-30350
06/29/2022, 5:59 PMfast-garage-66093
06/29/2022, 7:02 PMHOME
directory, but that didn't work properly either. So I'm out of ideas for now, beyond creating another username without a space in it, which is a bit drastic.fast-garage-66093
06/29/2022, 7:02 PMwhite-vegetable-30350
06/29/2022, 7:03 PMfast-garage-66093
06/29/2022, 7:04 PMmaster
)fast-garage-66093
06/29/2022, 7:05 PMfast-garage-66093
06/29/2022, 7:55 PMwhite-vegetable-30350
06/30/2022, 3:38 PMwhite-vegetable-30350
08/12/2022, 4:31 PMfast-garage-66093
08/29/2022, 3:18 PMwhite-vegetable-30350
02/06/2023, 4:30 PMfast-garage-66093
02/06/2023, 4:51 PMacceptable-soccer-28720
02/07/2023, 1:51 PM