roles/nextcloud: Switch to Fedora package
Fedora now includes a packaged version of Nextcloud. This will be _much_ easier to maintain than the tarball-based distribution method. There are some minor differences in how the Fedora package works, compared to the upstream tarball. Notably, it puts the configuration file in `/etc/` and makes it read-only, and it stores persistent data separate from the application. These differences require modifications to the Apache and PHP-FPM configuration, but the package also included examples to make this easier. Since the `config.php` is read-only now, it has to be managed by the configuration policy; it cannot be modified by the Administration web UI.
This commit is contained in:
52
roles/nextcloud/templates/config.php.j2
Normal file
52
roles/nextcloud/templates/config.php.j2
Normal file
@@ -0,0 +1,52 @@
|
||||
<?php
|
||||
$CONFIG = array (
|
||||
'config_is_read_only' => true,
|
||||
'htaccess.RewriteBase' => '/',
|
||||
'memcache.local' => '\\OC\\Memcache\\APCu',
|
||||
'apps_paths' =>
|
||||
array (
|
||||
0 =>
|
||||
array (
|
||||
'path' => '/usr/share/nextcloud/apps',
|
||||
'url' => '/apps',
|
||||
'writable' => false,
|
||||
),
|
||||
1 =>
|
||||
array (
|
||||
'path' => '/var/lib/nextcloud/apps',
|
||||
'url' => '/apps-appstore',
|
||||
'writable' => true,
|
||||
),
|
||||
),
|
||||
'instanceid' => '{{ nextcloud_instanceid }}',
|
||||
'passwordsalt' => '{{ nextcloud_passwordsalt }}',
|
||||
'secret' => '{{ nextcloud_secret }}',
|
||||
'trusted_proxies' =>
|
||||
array (
|
||||
{% for addr in nextcloud_trusted_proxies %}
|
||||
{{ loop.index0 }} => '{{ addr }}',
|
||||
{% endfor %}
|
||||
),
|
||||
'trusted_domains' =>
|
||||
array (
|
||||
{% for name in nextcloud_trusted_domains %}
|
||||
{{ loop.index0 }} => '{{ name }}',
|
||||
{% endfor %}
|
||||
),
|
||||
'datadirectory' => '/var/lib/nextcloud/data',
|
||||
'dbtype' => 'pgsql',
|
||||
'version' => '20.0.8.1',
|
||||
'overwrite.cli.url' => 'https://{{ nextcloud_server_name }}',
|
||||
'dbname' => 'nextcloud',
|
||||
'dbhost' => 'localhost',
|
||||
'dbport' => '',
|
||||
'dbtableprefix' => 'oc_',
|
||||
'dbuser' => 'nextcloud',
|
||||
'dbpassword' => '{{ nextcloud_db_password }}',
|
||||
'installed' => true,
|
||||
'ldapIgnoreNamingRules' => false,
|
||||
'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
|
||||
'maintenance' => {{ nextcloud_maintenance|bool|string|lower }},
|
||||
'theme' => '',
|
||||
'loglevel' => 2,
|
||||
);
|
||||
Reference in New Issue
Block a user