1 { lib, pkgs, config, myconfig, mylibs, ... }:
3 adminer = pkgs.callPackage ../../commons/adminer.nix {};
4 ympd = pkgs.callPackage ./ympd.nix {
5 env = myconfig.env.tools.ympd;
7 ttrss = pkgs.callPackage ./ttrss.nix {
8 inherit (mylibs) fetchedGithub fetchedGit;
9 env = myconfig.env.tools.ttrss;
11 roundcubemail = pkgs.callPackage ./roundcubemail.nix { env = myconfig.env.tools.roundcubemail; };
12 wallabag = pkgs.callPackage ./wallabag.nix { env = myconfig.env.tools.wallabag; };
13 yourls = pkgs.callPackage ./yourls.nix {
14 inherit (mylibs) fetchedGithub;
15 env = myconfig.env.tools.yourls;
17 rompr = pkgs.callPackage ./rompr.nix {
18 inherit (mylibs) fetchedGithub;
19 env = myconfig.env.tools.rompr;
21 shaarli = pkgs.callPackage ./shaarli.nix {
22 env = myconfig.env.tools.shaarli;
24 dokuwiki = pkgs.callPackage ./dokuwiki.nix {
25 inherit (mylibs) fetchedGithub;
28 cfg = config.services.myWebsites.tools.tools;
30 options.services.myWebsites.tools.tools = {
31 enable = lib.mkEnableOption "enable tools website";
34 config = lib.mkIf cfg.enable {
35 security.acme.certs."eldiron".extraDomains."tools.immae.eu" = null;
37 services.myWebsites.tools.modules =
38 adminer.apache.modules
39 ++ ympd.apache.modules
40 ++ ttrss.apache.modules
41 ++ roundcubemail.apache.modules
42 ++ wallabag.apache.modules
43 ++ yourls.apache.modules
44 ++ rompr.apache.modules
45 ++ shaarli.apache.modules
46 ++ dokuwiki.apache.modules;
48 services.ympd = ympd.config // { enable = true; };
50 services.myWebsites.tools.vhostConfs.tools = {
52 hosts = ["tools.immae.eu" ];
55 adminer.apache.vhostConf
57 ttrss.apache.vhostConf
58 roundcubemail.apache.vhostConf
59 wallabag.apache.vhostConf
60 yourls.apache.vhostConf
61 rompr.apache.vhostConf
62 shaarli.apache.vhostConf
63 dokuwiki.apache.vhostConf
67 services.myPhpfpm.poolConfigs = {
68 adminer = adminer.phpFpm.pool;
69 ttrss = ttrss.phpFpm.pool;
70 roundcubemail = roundcubemail.phpFpm.pool;
71 wallabag = wallabag.phpFpm.pool;
72 yourls = yourls.phpFpm.pool;
73 rompr = rompr.phpFpm.pool;
74 shaarli = shaarli.phpFpm.pool;
75 dokuwiki = dokuwiki.phpFpm.pool;
78 system.activationScripts = {
79 ttrss = ttrss.activationScript;
80 roundcubemail = roundcubemail.activationScript;
81 wallabag = wallabag.activationScript;
82 yourls = yourls.activationScript;
83 rompr = rompr.activationScript;
84 shaarli = shaarli.activationScript;
85 dokuwiki = dokuwiki.activationScript;
88 systemd.services.tt-rss = {
89 description = "Tiny Tiny RSS feeds update daemon";
92 ExecStart = "${pkgs.php}/bin/php ${ttrss.webRoot}/update.php --daemon";
93 StandardOutput = "syslog";
94 StandardError = "syslog";
95 PermissionsStartOnly = true;
98 wantedBy = [ "multi-user.target" ];
99 requires = ["postgresql.service"];
100 after = ["network.target" "postgresql.service"];