diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2019-01-29 23:07:17 +0100 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2019-01-29 23:07:38 +0100 |
commit | dc9fb82633b0354630476c2547dafd8ff1bfb3f1 (patch) | |
tree | 8d10c99c2aee0c9fbc7802f65b2e637a70740782 /nixops/modules | |
parent | 24a7da33965001415edb022245b289bb5fc49a07 (diff) | |
download | Nix-dc9fb82633b0354630476c2547dafd8ff1bfb3f1.tar.gz Nix-dc9fb82633b0354630476c2547dafd8ff1bfb3f1.tar.zst Nix-dc9fb82633b0354630476c2547dafd8ff1bfb3f1.zip |
Add Denise&Jerome's website
Fixes https://git.immae.eu/mantisbt/view.php?id=73
Diffstat (limited to 'nixops/modules')
-rw-r--r-- | nixops/modules/websites/default.nix | 2 | ||||
-rw-r--r-- | nixops/modules/websites/ftp/denisejerome.nix | 48 | ||||
-rw-r--r-- | nixops/modules/websites/ftp/denisejerome_goaccess.conf | 99 |
3 files changed, 149 insertions, 0 deletions
diff --git a/nixops/modules/websites/default.nix b/nixops/modules/websites/default.nix index 3b3ccc2..4a6a26f 100644 --- a/nixops/modules/websites/default.nix +++ b/nixops/modules/websites/default.nix | |||
@@ -94,6 +94,7 @@ in | |||
94 | ./ftp/jerome.nix | 94 | ./ftp/jerome.nix |
95 | ./ftp/nassime.nix | 95 | ./ftp/nassime.nix |
96 | ./ftp/florian.nix | 96 | ./ftp/florian.nix |
97 | ./ftp/denisejerome.nix | ||
97 | ./tools/db | 98 | ./tools/db |
98 | ./tools/tools | 99 | ./tools/tools |
99 | ./tools/dav | 100 | ./tools/dav |
@@ -193,6 +194,7 @@ in | |||
193 | services.myWebsites.Jerome.production.enable = cfg.production.enable; | 194 | services.myWebsites.Jerome.production.enable = cfg.production.enable; |
194 | services.myWebsites.Nassime.production.enable = cfg.production.enable; | 195 | services.myWebsites.Nassime.production.enable = cfg.production.enable; |
195 | services.myWebsites.Florian.production.enable = cfg.production.enable; | 196 | services.myWebsites.Florian.production.enable = cfg.production.enable; |
197 | services.myWebsites.DeniseJerome.production.enable = cfg.production.enable; | ||
196 | 198 | ||
197 | services.myWebsites.Chloe.integration.enable = cfg.integration.enable; | 199 | services.myWebsites.Chloe.integration.enable = cfg.integration.enable; |
198 | services.myWebsites.Ludivine.integration.enable = cfg.integration.enable; | 200 | services.myWebsites.Ludivine.integration.enable = cfg.integration.enable; |
diff --git a/nixops/modules/websites/ftp/denisejerome.nix b/nixops/modules/websites/ftp/denisejerome.nix new file mode 100644 index 0000000..2958d87 --- /dev/null +++ b/nixops/modules/websites/ftp/denisejerome.nix | |||
@@ -0,0 +1,48 @@ | |||
1 | { lib, pkgs, config, myconfig, mylibs, ... }: | ||
2 | let | ||
3 | cfg = config.services.myWebsites.DeniseJerome; | ||
4 | varDir = "/var/lib/ftp/denisejerome"; | ||
5 | env = myconfig.env.websites.denisejerome; | ||
6 | in { | ||
7 | options.services.myWebsites.DeniseJerome = { | ||
8 | production = { | ||
9 | enable = lib.mkEnableOption "enable Denise Jerome's website"; | ||
10 | }; | ||
11 | }; | ||
12 | |||
13 | imports = [ | ||
14 | ../commons/stats.nix | ||
15 | ]; | ||
16 | |||
17 | config = lib.mkIf cfg.production.enable { | ||
18 | services.myWebsites.commons.stats.enable = true; | ||
19 | services.myWebsites.commons.stats.sites = [ | ||
20 | { | ||
21 | name = "denisejerome.piedsjaloux.fr"; | ||
22 | conf = ./denisejerome_goaccess.conf; | ||
23 | } | ||
24 | ]; | ||
25 | |||
26 | security.acme.certs."denisejerome" = config.services.myCertificates.certConfig // { | ||
27 | domain = "denisejerome.piedsjaloux.fr"; | ||
28 | }; | ||
29 | |||
30 | services.myWebsites.production.vhostConfs.denisejerome = { | ||
31 | certName = "denisejerome"; | ||
32 | hosts = ["denisejerome.piedsjaloux.fr" ]; | ||
33 | root = varDir; | ||
34 | extraConfig = [ | ||
35 | '' | ||
36 | Use Stats denisejerome.piedsjaloux.fr | ||
37 | |||
38 | <Directory ${varDir}> | ||
39 | DirectoryIndex index.htm index.html | ||
40 | Options Indexes FollowSymLinks MultiViews Includes | ||
41 | AllowOverride AuthConfig | ||
42 | Require all granted | ||
43 | </Directory> | ||
44 | '' | ||
45 | ]; | ||
46 | }; | ||
47 | }; | ||
48 | } | ||
diff --git a/nixops/modules/websites/ftp/denisejerome_goaccess.conf b/nixops/modules/websites/ftp/denisejerome_goaccess.conf new file mode 100644 index 0000000..1379eae --- /dev/null +++ b/nixops/modules/websites/ftp/denisejerome_goaccess.conf | |||
@@ -0,0 +1,99 @@ | |||
1 | time-format %H:%M:%S | ||
2 | date-format %d/%b/%Y | ||
3 | |||
4 | #sur immae.eu | ||
5 | #log-format %v %h %^[%d:%t %^] "%r" %s %b "%R" "%u" $^ | ||
6 | |||
7 | log-format VCOMBINED | ||
8 | #= %v:%^ %h %^[%d:%t %^] "%r" %s %b "%R" "%u" | ||
9 | |||
10 | html-prefs {"theme":"bright","layout":"vertical"} | ||
11 | |||
12 | exclude-ip 188.165.209.148 | ||
13 | exclude-ip 178.33.252.96 | ||
14 | exclude-ip 2001:41d0:2:9c94::1 | ||
15 | exclude-ip 2001:41d0:2:9c94:: | ||
16 | exclude-ip 176.9.151.89 | ||
17 | exclude-ip 2a01:4f8:160:3445:: | ||
18 | exclude-ip 82.255.56.72 | ||
19 | |||
20 | no-query-string true | ||
21 | |||
22 | keep-db-files true | ||
23 | load-from-disk true | ||
24 | db-path /var/lib/goaccess/denisejerome.piedsjaloux.fr | ||
25 | |||
26 | ignore-panel REFERRERS | ||
27 | ignore-panel KEYPHRASES | ||
28 | |||
29 | static-file .css | ||
30 | static-file .js | ||
31 | static-file .jpg | ||
32 | static-file .png | ||
33 | static-file .gif | ||
34 | static-file .ico | ||
35 | static-file .jpeg | ||
36 | static-file .pdf | ||
37 | static-file .csv | ||
38 | static-file .mpeg | ||
39 | static-file .mpg | ||
40 | static-file .swf | ||
41 | static-file .woff | ||
42 | static-file .woff2 | ||
43 | static-file .xls | ||
44 | static-file .xlsx | ||
45 | static-file .doc | ||
46 | static-file .docx | ||
47 | static-file .ppt | ||
48 | static-file .pptx | ||
49 | static-file .txt | ||
50 | static-file .zip | ||
51 | static-file .ogg | ||
52 | static-file .mp3 | ||
53 | static-file .mp4 | ||
54 | static-file .exe | ||
55 | static-file .iso | ||
56 | static-file .gz | ||
57 | static-file .rar | ||
58 | static-file .svg | ||
59 | static-file .bmp | ||
60 | static-file .tar | ||
61 | static-file .tgz | ||
62 | static-file .tiff | ||
63 | static-file .tif | ||
64 | static-file .ttf | ||
65 | static-file .flv | ||
66 | #static-file .less | ||
67 | #static-file .ac3 | ||
68 | #static-file .avi | ||
69 | #static-file .bz2 | ||
70 | #static-file .class | ||
71 | #static-file .cue | ||
72 | #static-file .dae | ||
73 | #static-file .dat | ||
74 | #static-file .dts | ||
75 | #static-file .ejs | ||
76 | #static-file .eot | ||
77 | #static-file .eps | ||
78 | #static-file .img | ||
79 | #static-file .jar | ||
80 | #static-file .map | ||
81 | #static-file .mid | ||
82 | #static-file .midi | ||
83 | #static-file .ogv | ||
84 | #static-file .webm | ||
85 | #static-file .mkv | ||
86 | #static-file .odp | ||
87 | #static-file .ods | ||
88 | #static-file .odt | ||
89 | #static-file .otf | ||
90 | #static-file .pict | ||
91 | #static-file .pls | ||
92 | #static-file .ps | ||
93 | #static-file .qt | ||
94 | #static-file .rm | ||
95 | #static-file .svgz | ||
96 | #static-file .wav | ||
97 | #static-file .webp | ||
98 | |||
99 | |||