feat(garage): Add ambassadeurices sante website
All checks were successful
build configuration / build_compute01 (push) Successful in 1m3s
build configuration / build_storage01 (push) Successful in 1m6s
build configuration / build_vault01 (push) Successful in 1m4s
build configuration / build_web01 (push) Successful in 1m16s
build configuration / build_web02 (push) Successful in 49s
build configuration / build_rescue01 (push) Successful in 50s
lint / check (push) Successful in 20s
All checks were successful
build configuration / build_compute01 (push) Successful in 1m3s
build configuration / build_storage01 (push) Successful in 1m6s
build configuration / build_vault01 (push) Successful in 1m4s
build configuration / build_web01 (push) Successful in 1m16s
build configuration / build_web02 (push) Successful in 49s
build configuration / build_rescue01 (push) Successful in 50s
lint / check (push) Successful in 20s
This commit is contained in:
parent
84e439a89f
commit
a7664ce44b
1 changed files with 19 additions and 7 deletions
|
@ -1,4 +1,9 @@
|
||||||
{ config, pkgs, ... }:
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
host = "s3.dgnum.eu";
|
host = "s3.dgnum.eu";
|
||||||
|
@ -7,10 +12,13 @@ let
|
||||||
data_dir = "/data/slow/garage/data";
|
data_dir = "/data/slow/garage/data";
|
||||||
metadata_dir = "/data/fast/garage/meta";
|
metadata_dir = "/data/fast/garage/meta";
|
||||||
|
|
||||||
buckets = [
|
buckets = {
|
||||||
"castopod-dgnum"
|
"castopod-dgnum" = { };
|
||||||
"peertube-videos-dgnum"
|
"peertube-videos-dgnum" = { };
|
||||||
];
|
"boussole-sante.normalesup.eu" = {
|
||||||
|
mainDomain = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services.garage = {
|
services.garage = {
|
||||||
|
@ -68,7 +76,7 @@ in
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
|
|
||||||
serverAliases = builtins.map (b: "${b}.${host}") buckets;
|
serverAliases = builtins.map (b: "${b}.${host}") (builtins.attrNames buckets);
|
||||||
|
|
||||||
locations."/".extraConfig = ''
|
locations."/".extraConfig = ''
|
||||||
proxy_pass http://127.0.0.1:3900;
|
proxy_pass http://127.0.0.1:3900;
|
||||||
|
@ -84,7 +92,11 @@ in
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
|
|
||||||
serverAliases = builtins.map (b: "${b}.${webHost}") buckets;
|
serverAliases = lib.flatten (
|
||||||
|
lib.mapAttrsToList (
|
||||||
|
b: v: lib.singleton "${b}.${webHost}" ++ lib.optional (v ? mainDomain && v.mainDomain) b
|
||||||
|
) buckets
|
||||||
|
);
|
||||||
|
|
||||||
locations."/".extraConfig = ''
|
locations."/".extraConfig = ''
|
||||||
proxy_pass http://127.0.0.1:3902;
|
proxy_pass http://127.0.0.1:3902;
|
||||||
|
|
Loading…
Reference in a new issue