k8s-manifests/customers/base/nextcloud-configmap.yml

142 lines
4.5 KiB
YAML
Raw Normal View History

2023-03-27 14:41:43 +00:00
apiVersion: v1
kind: ConfigMap
metadata:
2023-03-28 21:14:35 +00:00
name: nextcloud-configmap
2023-03-28 21:46:34 +00:00
data:
2023-03-29 07:53:15 +00:00
000-default.conf: |
LoadModule remoteip_module /usr/lib/apache2/modules/mod_remoteip.so
Listen 8080
<VirtualHost *:8080>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
# Log format config
LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" common
SetEnvIf X-Forwarded-For "^.*\..*\..*\..*" forwarded
# Header config
RemoteIPHeader X-Forwarded-For
RemoteIPInternalProxy 37.156.195.11
RemoteIPInternalProxy 37.156.195.12
RemoteIPInternalProxy 37.156.195.21
RemoteIPInternalProxy 37.156.195.22
# TODO: Package 404 for k8s
# ErrorDocument 404 /404.html
ErrorLog /dev/stderr
TransferLog /dev/stdout
<Directory /var/www/html/>
LimitRequestBody 0
Require all granted
AllowOverride All
Options FollowSymLinks MultiViews
<IfModule mod_dav.c>
Dav off
</IfModule>
</Directory>
</VirtualHost>
2023-03-27 14:41:43 +00:00
config.php: |
<?php
$CONFIG = array (
'memcache.local' => '\\OC\\Memcache\\APCu',
'appstoreenabled' => false,
'apps_paths' =>
array (
0 =>
array (
'path' => '/var/www/html/apps',
'url' => '/apps',
'writable' => false,
),
1 =>
array (
'path' => '/var/www/html/custom_apps',
'url' => '/custom_apps',
'writable' => true,
),
),
'memcache.distributed' => '\\OC\\Memcache\\Redis',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'redis' =>
array (
'host' => '{{REDIS_HOST}}',
'password' => '{{REDIS_PASSWORD}}',
'port' => 6379,
),
'forcessl' => true,
'overwriteprotocol' => 'https',
'objectstore' =>
array (
'class' => '\\OC\\Files\\ObjectStore\\S3',
'arguments' =>
array (
'bucket' => '{{OBJECTSTORE_S3_BUCKET}}',
'key' => '{{OBJECTSTORE_S3_KEY}}',
'secret' => '{{OBJECTSTORE_S3_SECRET}}',
'region' => '{{OBJECTSTORE_S3_REGION}}',
'hostname' => '{{OBJECTSTORE_S3_HOST}}',
'port' => '',
'objectPrefix' => 'urn:oid:',
'autocreate' => false,
'use_ssl' => true,
'use_path_style' => true,
'legacy_auth' => false,
),
),
'csrf.disabled' => true,
'passwordsalt' => '{{NEXTCLOUD_PASSWORDSALT}}',
'secret' => '{{NEXTCLOUD_SECRET}}',
'trusted_domains' =>
array (
0 => '{{NEXTCLOUD_TRUSTED_DOMAINS}}'
),
'config_is_read_only' => true,
'datadirectory' => '/var/www/html/data',
'dbhost' => '{{MYSQL_HOST}}',
'dbname' => '{{MYSQL_DATABASE}}',
'dbpassword' => '{{MYSQL_PASSWORD}}',
'dbport' => '{{MYSQL_PORT}}',
'dbtableprefix' => 'oc_',
'dbtype' => 'mysql',
'dbuser' => '{{MYSQL_USER}}',
'gs.enabled' => 'true',
'gs.federation' => 'global',
'gs.trustedHosts' => ['*.sunet.se'],
'gss.jwt.key' => '{{GSS_JWT_KEY}}',
'gss.master.url' => '{{GSS_MASTER_URL}}',
'gss.mode' => 'slave',
'gss.user.discovery.module' => '\\OCA\\GlobalSiteSelector\\UserDiscoveryModules\\ManualUserMapping',
'installed' => true,
'instanceid' => '{{NEXTCLOUD_INSTANCEID}}',
'log_type' => 'file',
'loglevel' => 0,
'lookup_server' => '{{LOOKUP_SERVER}}',
'mail_domain' => '{{MAIL_DOMAIN}}',
'mail_from_address' => '{{MAIL_FROM_ADDRESS}}',
'mail_sendmailmode' => 'smtp',
'mail_smtpauth' => 1,
'mail_smtpauthtype' => 'LOGIN',
'mail_smtphost' => '{{MAIL_SMTPHOST}}',
'mail_smtpmode' => 'smtp',
'mail_smtpname' => '{{MAIL_SMTPNAME}}',
'mail_smtppassword' => '{{MAIL_SMTPPASSWORD}}',
'mail_smtpport' => '587',
'mail_smtpsecure' => 'tls',
'mail_template_class' => 'OCA\DriveEmailTemplate\EMailTemplate',
'mysql.utf8mb4' => true,
'overwritehost' => '{{SITE_NAME}}',
'overwrite.cli.url' => 'https://{{SITE_NAME}}',
'templatedirectory' => '',
'skeletondirectory' => '',
'twofactor_enforced' => 'true',
'twofactor_enforced_groups' =>
array (
0 => 'admin',
),
'version' => '{{NEXTCLOUD_VERSION_STRING}}',
'app_install_overwrite' =>
array (
0 => 'globalsiteselector',
),
);