add school wordpress site

This commit is contained in:
Schrottkatze 2024-02-21 09:25:07 +01:00
parent 5fc0e91a72
commit ac367b083b
Signed by: schrottkatze
SSH key fingerprint: SHA256:hXb3t1vINBFCiDCmhRABHX5ocdbLiKyCdKI4HK2Rbbc
3 changed files with 51 additions and 2 deletions

View file

@ -1,10 +1,10 @@
{ pkgs, ... }:
{
{pkgs, ...}: {
imports = [
./katzencafe-wiki.nix
./phtanumb-wiki.nix
./calckey.nix
./penpot.nix
./nextcloud.nix
./wordpress-schule.nix
];
}

View file

@ -0,0 +1,38 @@
{...}: {
containers."schule-wp" = {
autoStart = true;
privateNetwork = true;
hostAddress = "10.0.4.1";
localAddress = "10.0.4.2";
bindMounts = {
"/var/wp" = {
hostPath = "/schule-wp";
isReadOnly = false;
};
};
config = {
config,
pkgs,
...
}: {
services.wordpress = {
sites."schule" = {
virtualHost = {
hostName = "wp.schule.katzen.cafe";
adminAddr = "schule@schrottkatze.de";
listen = [
{
ip = "10.0.4.2";
port = 80;
ssl = false;
}
];
};
};
};
system.stateVersion = "23.11";
};
};
deployment.keys = {
};
}

View file

@ -58,6 +58,10 @@
group = "nginx";
keyType = "rsa4096";
};
"wp.schule.katzen.cafe" = {
group = "nginx";
keyType = "rsa4096";
};
# "prosody.katzen.cafe" = {
# group = "prosody";
# keyType = "rsa4096";
@ -204,6 +208,13 @@
add_header Strict-Transport-Security "max-age=15552000; includeSubDomains" always;
'';
};
"wp.schule.katzen.cafe" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://10.0.4.2";
};
};
};
};
}