aboutsummaryrefslogtreecommitdiff
path: root/nixops/modules/websites/tools/cloud
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2019-05-05 23:12:17 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2019-05-06 00:13:47 +0200
commit3a1461cf44102e6cd8cdee5e0f1ff1d7992894ad (patch)
treea8350184b1f4cf02267178c33b0190b595e7e5a3 /nixops/modules/websites/tools/cloud
parent0ede7366409e14482017f70f1efc53426279b8d0 (diff)
downloadNix-3a1461cf44102e6cd8cdee5e0f1ff1d7992894ad.tar.gz
Nix-3a1461cf44102e6cd8cdee5e0f1ff1d7992894ad.tar.zst
Nix-3a1461cf44102e6cd8cdee5e0f1ff1d7992894ad.zip
Upgrade nextcloud to 16.0
Diffstat (limited to 'nixops/modules/websites/tools/cloud')
-rw-r--r--nixops/modules/websites/tools/cloud/default.nix15
-rw-r--r--nixops/modules/websites/tools/cloud/nextcloud-config/mimetypealiases.json4
-rw-r--r--nixops/modules/websites/tools/cloud/nextcloud-config/mimetypemapping.json4
3 files changed, 11 insertions, 12 deletions
diff --git a/nixops/modules/websites/tools/cloud/default.nix b/nixops/modules/websites/tools/cloud/default.nix
index f7d25cf..a7fcd61 100644
--- a/nixops/modules/websites/tools/cloud/default.nix
+++ b/nixops/modules/websites/tools/cloud/default.nix
@@ -94,7 +94,7 @@ in {
94 'passwordsalt' => '${env.password_salt}', 94 'passwordsalt' => '${env.password_salt}',
95 'debug' => false, 95 'debug' => false,
96 'dbtype' => 'pgsql', 96 'dbtype' => 'pgsql',
97 'version' => '15.0.4.0', 97 'version' => '16.0.0.9',
98 'dbname' => '${env.postgresql.database}', 98 'dbname' => '${env.postgresql.database}',
99 'dbhost' => '${env.postgresql.socket}', 99 'dbhost' => '${env.postgresql.socket}',
100 'dbtableprefix' => 'oc_', 100 'dbtableprefix' => 'oc_',
@@ -135,6 +135,7 @@ in {
135 'overwrite.cli.url' => 'https://cloud.immae.eu', 135 'overwrite.cli.url' => 'https://cloud.immae.eu',
136 'ldapIgnoreNamingRules' => false, 136 'ldapIgnoreNamingRules' => false,
137 'ldapProviderFactory' => '\\OCA\\User_LDAP\\LDAPProviderFactory', 137 'ldapProviderFactory' => '\\OCA\\User_LDAP\\LDAPProviderFactory',
138 'has_rebuilt_cache' => true,
138 ); 139 );
139 ''; 140 '';
140 }]; 141 }];
@@ -151,14 +152,20 @@ in {
151 in [ occ ]; 152 in [ occ ];
152 153
153 system.activationScripts.nextcloud = { 154 system.activationScripts.nextcloud = {
154 deps = [ ]; 155 deps = [ "secrets" ];
155 text = '' 156 text = let
157 confs = lib.attrsets.mapAttrs (n: v: pkgs.writeText "${n}.json" (builtins.toJSON v)) nextcloud.otherConfig;
158 in
159 ''
156 install -m 0755 -o wwwrun -g wwwrun -d ${varDir} 160 install -m 0755 -o wwwrun -g wwwrun -d ${varDir}
157 install -m 0750 -o wwwrun -g wwwrun -d ${varDir}/phpSessions 161 install -m 0750 -o wwwrun -g wwwrun -d ${varDir}/phpSessions
158 install -D -m 0644 -o wwwrun -g wwwrun ${./nextcloud-config}/* -t ${varDir}/config 162 ${builtins.concatStringsSep "\n" (lib.attrsets.mapAttrsToList (n: v:
163 "install -D -m 0644 -o wwwrun -g wwwrun -T ${v} ${varDir}/config/${n}.json"
164 ) confs)}
159 install -D -m 0600 -o wwwrun -g wwwrun -T /var/secrets/webapps/tools-nextcloud ${varDir}/config/config.php 165 install -D -m 0600 -o wwwrun -g wwwrun -T /var/secrets/webapps/tools-nextcloud ${varDir}/config/config.php
160 ''; 166 '';
161 }; 167 };
168 # FIXME: add a warning when config.php changes
162 system.extraSystemBuilderCmds = '' 169 system.extraSystemBuilderCmds = ''
163 mkdir -p $out/webapps 170 mkdir -p $out/webapps
164 ln -s ${nextcloud} $out/webapps/${webappName} 171 ln -s ${nextcloud} $out/webapps/${webappName}
diff --git a/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypealiases.json b/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypealiases.json
deleted file mode 100644
index 3806e53..0000000
--- a/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypealiases.json
+++ /dev/null
@@ -1,4 +0,0 @@
1{
2 "application/gpx+xml": "gpx",
3 "x-application/kdbx": "kdbx"
4}
diff --git a/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypemapping.json b/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypemapping.json
deleted file mode 100644
index 2db4691..0000000
--- a/nixops/modules/websites/tools/cloud/nextcloud-config/mimetypemapping.json
+++ /dev/null
@@ -1,4 +0,0 @@
1{
2 "gpx": ["application/gpx+xml"],
3 "kdbx": ["x-application/kdbx"]
4}