chore: better provisioned vm resources

This commit is contained in:
Nick 2025-11-24 19:28:55 -06:00
parent 936e8207d0
commit 1fa809d7f5
9 changed files with 15 additions and 20 deletions

View file

@ -168,8 +168,8 @@ in
}; };
microvm = { microvm = {
vcpu = 2; vcpu = 1;
mem = 3072; mem = 1024;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -120,8 +120,8 @@ in
systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ]; systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ];
microvm = { microvm = {
vcpu = 2; vcpu = 1;
mem = 3072; mem = 1024;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -82,8 +82,8 @@ in
systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ]; systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ];
microvm = { microvm = {
vcpu = 2; vcpu = 1;
mem = 1024 * 3; mem = 1024;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -397,8 +397,8 @@ in
environment.systemPackages = [ fedifetcherPython ]; environment.systemPackages = [ fedifetcherPython ];
microvm = { microvm = {
vcpu = 4; vcpu = 1;
mem = 1024 * 8; mem = 1024 * 6;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -83,8 +83,8 @@ in
systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ]; systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ];
microvm = { microvm = {
vcpu = 4; vcpu = 1;
mem = 4096; mem = 1024;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -9,7 +9,7 @@ let
inherit (flake.config.services) instances; inherit (flake.config.services) instances;
serviceCfg = instances.projectSite; serviceCfg = instances.projectSite;
host = flake.inputs.linkpage.secrets.domains.projectsite; host = flake.inputs.linkpage.secrets.domains.projectsite;
websitePkg = flake.inputs.linkpage.packages.${pkgs.system}.websiteFrontend; websitePkg = flake.inputs.linkpage.packages.${pkgs.stdenv.hostPlatform.system}.websiteFrontend;
in in
{ {
systemd.tmpfiles.rules = [ systemd.tmpfiles.rules = [

View file

@ -109,8 +109,8 @@ in
systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ]; systemd.services.systemd-networkd.wantedBy = [ "multi-user.target" ];
microvm = { microvm = {
vcpu = 2; vcpu = 1;
mem = 3072; mem = 1024;
hypervisor = "qemu"; hypervisor = "qemu";
interfaces = [ interfaces = [
{ {

View file

@ -9,7 +9,8 @@ let
inherit (flake.config.services) instances; inherit (flake.config.services) instances;
serviceCfg = instances.upRootNutrition; serviceCfg = instances.upRootNutrition;
host = serviceCfg.domains.url0; host = serviceCfg.domains.url0;
websitePkg = flake.inputs.upRootNutrition.packages.${pkgs.system}.websiteFrontend; websitePkg =
flake.inputs.upRootNutrition.packages.${pkgs.stdenv.hostPlatform.system}.websiteFrontend;
in in
{ {
microvm.vms.${serviceCfg.name} = { microvm.vms.${serviceCfg.name} = {

View file

@ -94,12 +94,6 @@ in
source = "/nix/store"; source = "/nix/store";
tag = "read_only_nix_store"; tag = "read_only_nix_store";
} }
{
mountPoint = "/var/lib/${serviceCfg.name}";
proto = "virtiofs";
source = serviceCfg.mntPaths.path0;
tag = "${serviceCfg.name}_data";
}
{ {
mountPoint = "/run/secrets"; mountPoint = "/run/secrets";
proto = "virtiofs"; proto = "virtiofs";