gyf304 / vmcli

A set of utilities (vmcli + vmctl) for macOS Virtualization.framework
BSD 2-Clause "Simplified" License
825 stars 44 forks source link

Working in monterey, however VM Linux not full configured #24

Open ruyrybeyro opened 3 years ago

ruyrybeyro commented 3 years ago

In Monterey 12.0.1, using an Intel i7 MacBook Pro, the virtual machine is created, however the Linux/provisioning script is lacking proper steps of initialization.

Found these issues:

I ended up changing root password, adding to the ubuntu.sh script :

send -- "echo 'root:root' | chpasswd\r" expect "# "

Then I added a netplan configuration, creating file /etc/netplan/00-installer-config.yaml

network: version: 2 renderer: networkd ethernets: enp0s1: dhcp4: true

(netplan file not well rendered here for some reason. There are indenting spaces)

Ran "netplan apply" as root, and enp0s1 immediately got an IP address.

Nevertheless, ssh service still did not go up at boot time, for the lack of host keys.

After creating a non-privileged user and running as root:

ssh-keygen -A

Was then able to use the ssh service, and copied manually my ssh keys.

Unrelated question, would the virtual disk image support qcow2?

dmarkey commented 2 years ago

Cloud-init looks to be a bit busted in my tests.