X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=nixops%2Fmodules%2Fwebsites%2Fludivine%2Fludivinecassal.nix;h=114c4ac2509d0eb7679ab3b07f7e2f4051dd5154;hb=a754e9dbf5d6c35398f3c4ec52c3daf5f8ed2dd3;hp=eff0bf8f762ed34104fb825e56239df578e6b5d6;hpb=01f21083a897b86bf148f1d2bb9c8edca4d3786a;p=perso%2FImmae%2FConfig%2FNix.git diff --git a/nixops/modules/websites/ludivine/ludivinecassal.nix b/nixops/modules/websites/ludivine/ludivinecassal.nix index eff0bf8..114c4ac 100644 --- a/nixops/modules/websites/ludivine/ludivinecassal.nix +++ b/nixops/modules/websites/ludivine/ludivinecassal.nix @@ -7,14 +7,14 @@ let writeText "parameters.yml" '' # This file is auto-generated during the composer install parameters: - database_host: db-1.immae.eu - database_port: null + database_host: ${config.mysql.host} + database_port: ${config.mysql.port} database_name: ${config.mysql.name} database_user: ${config.mysql.user} database_password: ${config.mysql.password} database_server_version: ${pkgs.mariadb.mysqlVersion} mailer_transport: smtp - mailer_host: mail.immae.eu + mailer_host: 127.0.0.1 mailer_user: null mailer_password: null secret: ${config.secret} @@ -60,10 +60,12 @@ let pm.max_spare_servers = 3 ''}''; }; - apache = { + apache = rec { user = "wwwrun"; group = "wwwrun"; modules = [ "proxy_fcgi" ]; + webappName = "ludivine_${environment}"; + root = "/run/current-system/webapps/${webappName}"; vhostConf = '' SetHandler "proxy:unix:${phpFpm.socket}|fcgi://localhost" @@ -76,7 +78,7 @@ let ErrorDocument 401 "" - + Options Indexes FollowSymLinks MultiViews Includes AllowOverride None Require all granted @@ -119,7 +121,7 @@ let '' else '' Use Stats ludivinecassal.com - + Options Indexes FollowSymLinks MultiViews Includes AllowOverride All Require all granted @@ -156,7 +158,7 @@ let # bug in leapt.im (searches for data/../miniatures) postInstall = '' rm -rf var/{logs,cache,data,miniatures,tmp} - ln -sf ../../../../../../../${varDir}/{logs,cache,data,miniatures,tmp} var/ + ln -sf ${varDir}/{logs,cache,data,miniatures,tmp} var/ ''; buildInputs = [ sass ]; });