-
Notifications
You must be signed in to change notification settings - Fork 602
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
External driver, for cloud and physical #2109
Comments
The hardware resources are specified by the user, matching the external: vmType: ext
arch: "aarch64"
cpus: 4
memory: 512MiB
disk: 32GiB
mounts:
- location: "~"
- location: "/tmp/lima"
writable: true
ssh:
address: raspberrypi.local The OS installation is supposed to be aligned, but is not using the "images". e.g. you would use the cloud web interface or the SD card image for Ubuntu |
Note that since machine start and stop are handled externally, it only affects the hostagent. The user is supposed to install and start the guestagent, and to install containerd/buildkitd. start
stop
The external server keeps running, including lima-guestagent and friends. Now also includes support for provisioning, as shown in the above output. provision:
- mode: system
script: |
#!/bin/sh
touch /tmp/foo
- mode: user
script: |
#!/bin/bash
set -eux -o pipefail
touch /tmp/bar
probes:
- script: |
#!/bin/bash
set -eux -o pipefail
if ! timeout 10 bash -c "until test -e /tmp/foo >/dev/null 2>&1; do sleep 3; done"; then
echo >&2 "foo is not touched yet"
exit 1
fi
- script: |
#!/bin/bash
set -eux -o pipefail
if ! timeout 10 bash -c "until test -e /tmp/bar >/dev/null 2>&1; do sleep 3; done"; then
echo >&2 "bar is not touched yet"
exit 1
fi |
Changed output for non-localhost:
Into a slightly more interesting IP:
|
Description
Add a generic driver for external virtual machines and physical servers.
It is similar to running
ssh
, but includes all the Lima features like agent.The user is supposed to have an existing server, with key-based ssh login.
Previously it was hardcoding
127.0.0.1
as the hostnameHost keys are being used (and should be set up), to verify the external server.
Previously it was hardcoding
StrictHostKeyChecking=no
A
guest-install
command is added, to install lima-guestagent and nerdctl-full.The external machine lifecycle (boot/reboot/etc) is managed outside of Lima.
Tested with Digital Ocean, and with Raspberry Pi.
Note: this driver does not create cloud instances.
The text was updated successfully, but these errors were encountered: