-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathlima.yaml
More file actions
45 lines (43 loc) · 1.34 KB
/
lima.yaml
File metadata and controls
45 lines (43 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
images:
- location: https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-genericcloud-amd64.qcow2
arch: x86_64
- location: https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-genericcloud-arm64.qcow2
arch: aarch64
cpus: 6
memory: 12GiB
disk: 100GiB
user:
name: debian
uid: 1000
home: /home/debian
vmOpts:
vz:
rosetta:
enabled: true
binfmt: true
containerd:
# Otherwise lima will install couple of hundreds of MB of containerd stuff,
# which we don't need.
user: false
mountTypesUnsupported: [9p]
ssh:
forwardAgent: true
provision:
- mode: system
script: |
#!/bin/bash
set -euo pipefail
apt-get update
apt-get install -y curl git sudo debian-archive-keyring build-essential uidmap
echo "debian ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/debian
- mode: user
script: |
#!/bin/bash
set -euo pipefail
mkdir -p ~/.config/nix
echo 'experimental-features = nix-command flakes' > ~/.config/nix/nix.conf
echo 'extra-platforms = x86_64-linux' >> ~/.config/nix/nix.conf
sh <(curl -L https://nixos.org/nix/install) --no-daemon --nix-extra-conf-file ~/.config/nix/nix.conf
# nix adds its env to .profile, but not to .bashrc
# .profile is not sourced when connecting through ssh, so copy to .bashrc
grep nix .profile >> .bashrc