aboutsummaryrefslogtreecommitdiff
path: root/nix/machines/vm-synology/disk.nix
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2025-06-30 10:36:00 -0700
committerFranck Cuny <franck@fcuny.net>2025-06-30 10:36:00 -0700
commitce68c0a9e4c4ce78c48868219e4e5bcda849e228 (patch)
tree208bd056e4dfdd37bc1bd1c2134145c0d04b7da7 /nix/machines/vm-synology/disk.nix
parentonly include some home-manager configurations on Darwin (diff)
downloadinfra-ce68c0a9e4c4ce78c48868219e4e5bcda849e228.tar.gz
add configuration for vm-synology
This is a VM running on the Synology NAS. For now it only run `gitolite`, but we may host additional services in the future.
Diffstat (limited to 'nix/machines/vm-synology/disk.nix')
-rw-r--r--nix/machines/vm-synology/disk.nix55
1 files changed, 55 insertions, 0 deletions
diff --git a/nix/machines/vm-synology/disk.nix b/nix/machines/vm-synology/disk.nix
new file mode 100644
index 0000000..1641339
--- /dev/null
+++ b/nix/machines/vm-synology/disk.nix
@@ -0,0 +1,55 @@
+{ lib, ... }:
+{
+ disko.devices = {
+ disk.disk1 = {
+ device = lib.mkDefault "/dev/sda";
+ type = "disk";
+ content = {
+ type = "gpt";
+ partitions = {
+ boot = {
+ name = "boot";
+ size = "1M";
+ type = "EF02";
+ };
+ esp = {
+ name = "ESP";
+ size = "500M";
+ type = "EF00";
+ content = {
+ type = "filesystem";
+ format = "vfat";
+ mountpoint = "/boot";
+ };
+ };
+ root = {
+ name = "root";
+ size = "100%";
+ content = {
+ type = "lvm_pv";
+ vg = "pool";
+ };
+ };
+ };
+ };
+ };
+ lvm_vg = {
+ pool = {
+ type = "lvm_vg";
+ lvs = {
+ root = {
+ size = "100%FREE";
+ content = {
+ type = "filesystem";
+ format = "ext4";
+ mountpoint = "/";
+ mountOptions = [
+ "defaults"
+ ];
+ };
+ };
+ };
+ };
+ };
+ };
+}