Lima und MAC begonnen
This commit is contained in:
@@ -0,0 +1,91 @@
|
|||||||
|
# Lima
|
||||||
|
|
||||||
|
## Arbeitspfad
|
||||||
|
|
||||||
|
`export LIMA_HOME=/Volumes/untitled/lima`
|
||||||
|
|
||||||
|
## Konfig-File
|
||||||
|
```yaml
|
||||||
|
images:
|
||||||
|
- location: "https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-genericcloud-arm64.qcow2"
|
||||||
|
arch: aarch64
|
||||||
|
|
||||||
|
cpus: 4
|
||||||
|
memory: "8GiB"
|
||||||
|
disk: "50GiB"
|
||||||
|
|
||||||
|
mounts:
|
||||||
|
- location: "~/projects"
|
||||||
|
writable: true
|
||||||
|
|
||||||
|
ssh:
|
||||||
|
loadDotSSHPubKeys: true
|
||||||
|
|
||||||
|
provision:
|
||||||
|
- mode: system
|
||||||
|
script: |
|
||||||
|
#!/bin/bash
|
||||||
|
apt-get update
|
||||||
|
apt-get install -y \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
vim \
|
||||||
|
build-essential
|
||||||
|
|
||||||
|
containerd:
|
||||||
|
system: false
|
||||||
|
user: false
|
||||||
|
```
|
||||||
|
|
||||||
|
## Start
|
||||||
|
|
||||||
|
`limactl start debian12.yaml`
|
||||||
|
|
||||||
|
später nur
|
||||||
|
|
||||||
|
`limactl start debian12`
|
||||||
|
|
||||||
|
## Stop
|
||||||
|
|
||||||
|
```
|
||||||
|
limactl stop debian12
|
||||||
|
```
|
||||||
|
|
||||||
|
## Löschen
|
||||||
|
|
||||||
|
```
|
||||||
|
limactl delete debian12
|
||||||
|
```
|
||||||
|
|
||||||
|
## Liste
|
||||||
|
|
||||||
|
```
|
||||||
|
limactl list
|
||||||
|
```
|
||||||
|
|
||||||
|
## Einloggen
|
||||||
|
|
||||||
|
```
|
||||||
|
limactl shell debian12
|
||||||
|
```
|
||||||
|
|
||||||
|
(Instanzname standardmäßig aus Dateiname)
|
||||||
|
|
||||||
|
## SSH kontrollieren
|
||||||
|
|
||||||
|
`limactl show-ssh debian12`
|
||||||
|
|
||||||
|
```
|
||||||
|
`WARN[0000] `limactl show-ssh` is deprecated. Instead, use `ssh -F /Volumes/untitled/lima/debian12/ssh.config lima-debian12`.
|
||||||
|
ssh -o 'IdentityFile="/Volumes/untitled/lima/_config/user"' -o 'IdentityFile="/Users/svenriwoldt/.ssh/id_rsa"' -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o NoHostAuthenticationForLocalhost=yes -o PreferredAuthentications=publickey -o Compression=no -o BatchMode=yes -o IdentitiesOnly=yes -o GSSAPIAuthentication=no -o 'Ciphers="^aes128-gcm@openssh.com,aes256-gcm@openssh.com"' -o User=svenriwoldt -o ControlMaster=auto -o 'ControlPath="/Volumes/untitled/lima/debian12/ssh.sock"' -o ControlPersist=yes -o Hostname=127.0.0.1 -o Port=61315 lima-debian12
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## SCP
|
||||||
|
|
||||||
|
scp -P 61315 -i /Users/svenriwoldt/.ssh/id_rsa PF_neu.tgz 127.0.0.1:
|
||||||
|
|
||||||
|
## Editieren der Instanz
|
||||||
|
|
||||||
|
limactl edit debian12
|
||||||
Reference in New Issue
Block a user