hosts: add ooksmedia
This commit is contained in:
parent
f3895ce019
commit
10816d1a0a
10 changed files with 301 additions and 27 deletions
|
|
@ -87,27 +87,33 @@
|
|||
hostname,
|
||||
system,
|
||||
type,
|
||||
profile,
|
||||
services,
|
||||
profile ? null,
|
||||
domain ? "",
|
||||
additionalModules ? [],
|
||||
specialArgs ? {},
|
||||
}:
|
||||
mkBaseSystem {
|
||||
inherit withSystem hostname system type specialArgs;
|
||||
role = "server";
|
||||
additionalModules = concatLists [
|
||||
(singleton {
|
||||
ooknet.server = {
|
||||
inherit domain services;
|
||||
};
|
||||
})
|
||||
core
|
||||
[(serverModules + "/profiles/${profile}")]
|
||||
[serverModules]
|
||||
additionalModules
|
||||
];
|
||||
};
|
||||
assert lib.assertMsg (!(type == "vm" && profile == null))
|
||||
"Profile must be specified for VM servers";
|
||||
mkBaseSystem {
|
||||
inherit withSystem hostname system type specialArgs;
|
||||
role = "server";
|
||||
additionalModules = concatLists [
|
||||
(singleton {
|
||||
ooknet.server = {
|
||||
inherit domain services;
|
||||
};
|
||||
})
|
||||
core
|
||||
(
|
||||
if type == "vm"
|
||||
then [(serverModules + "/profiles/${profile}")]
|
||||
else [(hostModules + "/${hostname}")]
|
||||
)
|
||||
[serverModules]
|
||||
additionalModules
|
||||
];
|
||||
};
|
||||
|
||||
mkImage = {
|
||||
profile,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue