tadpole: Assert that nginx is running when using gitea
This commit is contained in:
@@ -7,8 +7,6 @@
|
|||||||
let
|
let
|
||||||
conf = config.mod.gitea;
|
conf = config.mod.gitea;
|
||||||
gitDomain = "git.${conf.baseDomain}";
|
gitDomain = "git.${conf.baseDomain}";
|
||||||
|
|
||||||
nginxEnable = config.mod.nginx.enable;
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options = {
|
options = {
|
||||||
@@ -37,8 +35,12 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf (conf.enable && nginxEnable) {
|
config = lib.mkIf conf.enable {
|
||||||
assertions = [
|
assertions = [
|
||||||
|
{
|
||||||
|
assertion = config.services.nginx.enable;
|
||||||
|
message = "Option 'config.services.nginx' must be enabled";
|
||||||
|
}
|
||||||
{
|
{
|
||||||
assertion = conf.baseDomain != "";
|
assertion = conf.baseDomain != "";
|
||||||
message = "Option 'mod.gitea.baseDomain' cannot be empty";
|
message = "Option 'mod.gitea.baseDomain' cannot be empty";
|
||||||
|
|||||||
Reference in New Issue
Block a user