From 3c1f43b23661c6e7a5dbc99db87d26e18a6a958f Mon Sep 17 00:00:00 2001 From: jopejoe1 Date: Sun, 5 May 2024 09:56:19 +0200 Subject: [PATCH] add wordpress --- systems/hetzner/nginx.nix | 59 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/systems/hetzner/nginx.nix b/systems/hetzner/nginx.nix index 4f5583d..a4fe842 100644 --- a/systems/hetzner/nginx.nix +++ b/systems/hetzner/nginx.nix @@ -44,4 +44,63 @@ protocolUseSSL = true; }; }; + + services.wordpress.webserver = "nginx"; + + services.wordpress.sites."test.missing.ninja" = + let + madara = pkgs.stdenv.mkDerivation rec { + name = "madara"; + version = "1.7.4.1"; + src = pkgs.fetchzip { + url = "file://var/dl/madara-${version}.zip"; + hash = ""; + }; + installPhase = "mkdir -p $out; cp -R * $out/"; + }; + madara-child = pkgs.stdenv.mkDerivation rec { + name = "madara-child"; + version = "1.0.3"; + src = pkgs.fetchzip { + url = "file://var/dl/madara-child-${version}.zip"; + hash = ""; + }; + installPhase = "mkdir -p $out; cp -R * $out/"; + }; + madara-core = pkgs.stdenv.mkDerivation rec { + name = "madara-core"; + version = "1.7.4.1"; + src = pkgs.fetchzip { + url = "file://var/dl/madara-core-${version}.zip"; + hash = ""; + }; + installPhase = "mkdir -p $out; cp -R * $out/"; + }; + madara-shortcodes = pkgs.stdenv.mkDerivation rec { + name = "madara-shortcodes"; + version = "1.5.5.9"; + src = pkgs.fetchzip { + url = "file://var/dl/madara-shortcodes-${version}.zip"; + hash = ""; + }; + installPhase = "mkdir -p $out; cp -R * $out/"; + }; + option-tree-lean = pkgs.stdenv.mkDerivation rec { + name = "option-tree-lean"; + version = "0"; + src = pkgs.fetchzip { + url = "file://var/dl/option-tree-lean.zip"; + hash = ""; + }; + installPhase = "mkdir -p $out; cp -R * $out/"; + }; + in + { + settings = { + FORCE_SSL_ADMIN = true; + }; + extraConfig = '' + $_SERVER['HTTPS']='on'; + ''; + }; }