You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+6-36
Original file line number
Diff line number
Diff line change
@@ -119,16 +119,16 @@ For NixOS:
119
119
120
120
```bash
121
121
# deploy one of the configuration based on the hostname
122
-
sudo nixos-rebuild switch --flake .#ai_i3
123
-
#sudo nixos-rebuild switch --flake .#ai-hyprland
122
+
#sudo nixos-rebuild switch --flake .#ai_i3
123
+
sudo nixos-rebuild switch --flake .#ai-hyprland
124
124
125
125
# deploy via `just`(a command runner with similar syntax to make) & Justfile
126
-
just i3 # deploy my pc with i3 window manager
127
-
#just hypr # deploy my pc with hyprland compositor
126
+
#just i3 # deploy my pc with i3 window manager
127
+
just hypr # deploy my pc with hyprland compositor
128
128
129
129
# or we can deploy with details
130
-
just i3 debug
131
-
#just hypr-debug
130
+
#just i3 debug
131
+
just hypr-debug
132
132
```
133
133
134
134
For macOS:
@@ -155,36 +155,6 @@ just ha debug
155
155
> [What y'all will need when Nix drives you to drink.](https://www.youtube.com/watch?v=Eni9PPPPBpg)
156
156
> (copy from hlissner's dotfiles, it really matches my feelings when I first started using NixOS...)
157
157
158
-
## How to create & managage VM from this flake?
159
-
160
-
use `aquamarine` as an example, we can create a virtual machine with the following command:
161
-
162
-
```shell
163
-
# 1. generate a proxmox vma image file
164
-
nom build .#aquamarine # `nom`(nix-output-monitor) can be replaced by the standard command `nix`
165
-
166
-
# 2. upload the generated image to proxmox server's backup directory `/var/lib/vz/dump`
167
-
# please replace the vma file name with the one you generated in step 1.
168
-
rsync -avz --progress --copy-links result root@um560:/var/lib/vz/dump/vzdump-qemu-aquamarine.vma.zst
169
-
170
-
# 3. the image we uploaded will be listed in proxmox web ui's this page: [storage 'local'] -> [backups], we can restore a vm from it via the web ui now.
171
-
```
172
-
173
-
Once the virtual machine `aquamarine` is created, we can deploy updates to it with the following
174
-
commands:
175
-
176
-
```shell
177
-
# 1. add the ssh key to ssh-agent
178
-
ssh-add /etc/agenix/ssh-key-romantic
179
-
180
-
# 2. deploy the configuration to all the remote host with tag `@dist-build`
181
-
# using the ssh key we added in step 1
182
-
colmena apply --on '@dist-build' --show-trace
183
-
```
184
-
185
-
If you're not familiar with remote deployment, please read this tutorial first:
0 commit comments