Skip to content

Commit

Permalink
test linuxcontainer
Browse files Browse the repository at this point in the history
  • Loading branch information
archmagece committed Mar 21, 2024
1 parent ce6a818 commit 6ae7657
Show file tree
Hide file tree
Showing 32 changed files with 2,535 additions and 0 deletions.
26 changes: 26 additions & 0 deletions charts/nextcloud-lc/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/

# pre
pre/
25 changes: 25 additions & 0 deletions charts/nextcloud-lc/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
apiVersion: v2
name: nextcloud-lc
version: 4.5.41
appVersion: 28.0.3
description: A file sharing server that puts the control and security of your own data back into your hands.
keywords:
- nextcloud
- storage
- http
- web
- php
home: https://nextcloud.com/
icon: https://raw.githubusercontent.com/ScriptonBasestar-docker/sb-helm-charts/master/helms/nextcloud/icon.png
sources:
- https://github.com/nextcloud/helm
- https://github.com/nextcloud/docker
- https://scriptonbasestar-docker.github.io/sb-helm-charts/
- https://github.com/linuxserver/docker-nextcloud
- https://hub.docker.com/r/linuxserver/nextcloud
maintainers:
- name: archmagece
email: [email protected]



661 changes: 661 additions & 0 deletions charts/nextcloud-lc/LICENSE.md

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions charts/nextcloud-lc/files/apcu.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?php
$CONFIG = array (
'memcache.local' => '\OC\Memcache\APCu',
);
29 changes: 29 additions & 0 deletions charts/nextcloud-lc/files/auto.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?php

$autoconfig_enabled = false;

if (getenv('MYSQL_DATABASE') && getenv('MYSQL_USER') && getenv('MYSQL_PASSWORD') && getenv('MYSQL_HOST')) {
$AUTOCONFIG['dbtype'] = 'mysql';
$AUTOCONFIG['dbname'] = getenv('MYSQL_DATABASE');
$AUTOCONFIG['dbuser'] = getenv('MYSQL_USER');
$AUTOCONFIG['dbpass'] = getenv('MYSQL_PASSWORD');
$AUTOCONFIG['dbhost'] = getenv('MYSQL_HOST');
$autoconfig_enabled = true;
} elseif (getenv('POSTGRES_DB') && getenv('POSTGRES_USER') && getenv('POSTGRES_PASSWORD') && getenv('POSTGRES_HOST')) {
$AUTOCONFIG['dbtype'] = 'pgsql';
$AUTOCONFIG['dbname'] = getenv('POSTGRES_DB');
$AUTOCONFIG['dbuser'] = getenv('POSTGRES_USER');
$AUTOCONFIG['dbpass'] = getenv('POSTGRES_PASSWORD');
$AUTOCONFIG['dbhost'] = getenv('POSTGRES_HOST');
$autoconfig_enabled = true;
} else {
$AUTOCONFIG['dbtype'] = 'sqlite';
$AUTOCONFIG['dbname'] = 'tmp-db';
$autoconfig_enabled = true;
}

if ($autoconfig_enabled) {
$AUTOCONFIG['directory'] = getenv('NEXTCLOUD_DATA_DIR') ?: '/var/www/html/data';
}

$AUTOCONFIG['config_is_read_only'] = false;
53 changes: 53 additions & 0 deletions charts/nextcloud-lc/files/config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
<?php
$CONFIG = array (
'memcache.local' => '\\OC\\Memcache\\APCu',
'apps_paths' =>
array (
0 =>
array (
'path' => '/var/www/html/apps',
'url' => '/apps',
'writable' => false,
),
1 =>
array (
'path' => '/nextcloud/custom_apps',
'url' => '/custom_apps',
'writable' => true,
),
),
'datadirectory' => '/nextcloud/data',
'memcache.distributed' => '\\OC\\Memcache\\Redis',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'redis' =>
array (
'host' => 'redis-master.data.svc.cluster.local',
'password' => 'i^txoGxLHYGFMS22',
'port' => 6379,
),
'overwritehost' => 'nas.polypia.net',
'overwriteprotocol' => 'https',
'overwrite.cli.url' => 'https://nas.polypia.net',
'trusted_proxies' =>
array (
0 => '10.42.0.0/16',
),
'upgrade.disable-web' => true,
'passwordsalt' => 'wsckkbyenEQfgY22Gfue6ouF/YLXZV',
'secret' => 'WdcHYhIjaKVqlNd2G81kOBUxy6eLWKlehp+cXKDOLH64lZYl',
'trusted_domains' =>
array (
0 => 'localhost',
1 => 'nas.polypia.net',
),
'dbtype' => 'pgsql',
'version' => '28.0.1.1',
'dbname' => 'nextcloud_db',
'dbhost' => 'postgresql.data.svc.cluster.local',
'dbport' => '',
'dbtableprefix' => 'oc_',
'dbuser' => 'nextcloud_user',
'dbpassword' => 'Lak#ej!!S9Y5zZRV!i',
'installed' => true,
'instanceid' => 'oc1fcrw8ev53',
);
20 changes: 20 additions & 0 deletions charts/nextcloud-lc/files/dir-apps.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?php
$directory_custom_apps = getenv('NEXTCLOUD_PATH_CUSTOM_APPS');
if (! $directory_custom_apps) {
$directory_custom_apps = OC::$SERVERROOT.'/custom_apps';
}

$CONFIG = array (
'apps_paths' => array (
0 => array (
'path' => OC::$SERVERROOT.'/apps',
'url' => '/apps',
'writable' => false,
),
1 => array (
'path' => $directory_custom_apps,
'url' => '/custom_apps',
'writable' => true,
),
),
);
8 changes: 8 additions & 0 deletions charts/nextcloud-lc/files/dir-data.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?php
$directory_data = getenv('NEXTCLOUD_PATH_DATA');
if (! $directory_data) {
$directory_data = OC::$SERVERROOT.'/data';
}
$CONFIG = array (
'datadirectory' => $directory_data,
);
17 changes: 17 additions & 0 deletions charts/nextcloud-lc/files/redis.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php
if (getenv('REDIS_HOST')) {
$CONFIG = array(
'memcache.distributed' => '\OC\Memcache\Redis',
'memcache.locking' => '\OC\Memcache\Redis',
'redis' => array(
'host' => getenv('REDIS_HOST'),
'password' => (string) getenv('REDIS_HOST_PASSWORD'),
),
);

if (getenv('REDIS_HOST_PORT') !== false) {
$CONFIG['redis']['port'] = (int) getenv('REDIS_HOST_PORT');
} elseif (getenv('REDIS_HOST')[0] != '/') {
$CONFIG['redis']['port'] = 6379;
}
}
30 changes: 30 additions & 0 deletions charts/nextcloud-lc/files/reverse-proxy.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?php
$overwriteHost = getenv('OVERWRITEHOST');
if ($overwriteHost) {
$CONFIG['overwritehost'] = $overwriteHost;
}

$overwriteProtocol = getenv('OVERWRITEPROTOCOL');
if ($overwriteProtocol) {
$CONFIG['overwriteprotocol'] = $overwriteProtocol;
}

$overwriteCliUrl = getenv('OVERWRITECLIURL');
if ($overwriteCliUrl) {
$CONFIG['overwrite.cli.url'] = $overwriteCliUrl;
}

$overwriteWebRoot = getenv('OVERWRITEWEBROOT');
if ($overwriteWebRoot) {
$CONFIG['overwritewebroot'] = $overwriteWebRoot;
}

$overwriteCondAddr = getenv('OVERWRITECONDADDR');
if ($overwriteCondAddr) {
$CONFIG['overwritecondaddr'] = $overwriteCondAddr;
}

$trustedProxies = getenv('TRUSTED_PROXIES');
if ($trustedProxies) {
$CONFIG['trusted_proxies'] = array_filter(array_map('trim', explode(' ', $trustedProxies)));
}
41 changes: 41 additions & 0 deletions charts/nextcloud-lc/files/s3.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<?php
if (getenv('OBJECTSTORE_S3_BUCKET')) {
$use_ssl = getenv('OBJECTSTORE_S3_SSL');
$use_path = getenv('OBJECTSTORE_S3_USEPATH_STYLE');
$use_legacyauth = getenv('OBJECTSTORE_S3_LEGACYAUTH');
$autocreate = getenv('OBJECTSTORE_S3_AUTOCREATE');
$CONFIG = array(
'objectstore' => array(
'class' => '\OC\Files\ObjectStore\S3',
'arguments' => array(
'bucket' => getenv('OBJECTSTORE_S3_BUCKET'),
'region' => getenv('OBJECTSTORE_S3_REGION') ?: '',
'hostname' => getenv('OBJECTSTORE_S3_HOST') ?: '',
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
// required for some non Amazon S3 implementations
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
// required for older protocol versions
'legacy_auth' => $use_legacyauth == true && strtolower($use_legacyauth) !== 'false'
)
)
);

if (getenv('OBJECTSTORE_S3_KEY_FILE') && file_exists(getenv('OBJECTSTORE_S3_KEY_FILE'))) {
$CONFIG['objectstore']['arguments']['key'] = trim(file_get_contents(getenv('OBJECTSTORE_S3_KEY_FILE')));
} elseif (getenv('OBJECTSTORE_S3_KEY')) {
$CONFIG['objectstore']['arguments']['key'] = getenv('OBJECTSTORE_S3_KEY');
} else {
$CONFIG['objectstore']['arguments']['key'] = '';
}

if (getenv('OBJECTSTORE_S3_SECRET_FILE') && file_exists(getenv('OBJECTSTORE_S3_SECRET_FILE'))) {
$CONFIG['objectstore']['arguments']['secret'] = trim(file_get_contents(getenv('OBJECTSTORE_S3_SECRET_FILE')));
} elseif (getenv('OBJECTSTORE_S3_SECRET')) {
$CONFIG['objectstore']['arguments']['secret'] = getenv('OBJECTSTORE_S3_SECRET');
} else {
$CONFIG['objectstore']['arguments']['secret'] = '';
}
}
22 changes: 22 additions & 0 deletions charts/nextcloud-lc/files/smtp.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?php
if (getenv('SMTP_HOST') && getenv('MAIL_FROM_ADDRESS') && getenv('MAIL_DOMAIN')) {
$CONFIG = array (
'mail_smtpmode' => 'smtp',
'mail_smtphost' => getenv('SMTP_HOST'),
'mail_smtpport' => getenv('SMTP_PORT') ?: (getenv('SMTP_SECURE') ? 465 : 25),
'mail_smtpsecure' => getenv('SMTP_SECURE') ?: '',
'mail_smtpauth' => getenv('SMTP_NAME') && (getenv('SMTP_PASSWORD') || (getenv('SMTP_PASSWORD_FILE') && file_exists(getenv('SMTP_PASSWORD_FILE')))),
'mail_smtpauthtype' => getenv('SMTP_AUTHTYPE') ?: 'LOGIN',
'mail_smtpname' => getenv('SMTP_NAME') ?: '',
'mail_from_address' => getenv('MAIL_FROM_ADDRESS'),
'mail_domain' => getenv('MAIL_DOMAIN'),
);

if (getenv('SMTP_PASSWORD_FILE') && file_exists(getenv('SMTP_PASSWORD_FILE'))) {
$CONFIG['mail_smtppassword'] = trim(file_get_contents(getenv('SMTP_PASSWORD_FILE')));
} elseif (getenv('SMTP_PASSWORD')) {
$CONFIG['mail_smtppassword'] = getenv('SMTP_PASSWORD');
} else {
$CONFIG['mail_smtppassword'] = '';
}
}
31 changes: 31 additions & 0 deletions charts/nextcloud-lc/files/swift.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?php
if (getenv('OBJECTSTORE_SWIFT_URL')) {
$autocreate = getenv('OBJECTSTORE_SWIFT_AUTOCREATE');
$CONFIG = array(
'objectstore' => [
'class' => 'OC\\Files\\ObjectStore\\Swift',
'arguments' => [
'autocreate' => $autocreate == true && strtolower($autocreate) !== 'false',
'user' => [
'name' => getenv('OBJECTSTORE_SWIFT_USER_NAME'),
'password' => getenv('OBJECTSTORE_SWIFT_USER_PASSWORD'),
'domain' => [
'name' => (getenv('OBJECTSTORE_SWIFT_USER_DOMAIN')) ?: 'Default',
],
],
'scope' => [
'project' => [
'name' => getenv('OBJECTSTORE_SWIFT_PROJECT_NAME'),
'domain' => [
'name' => (getenv('OBJECTSTORE_SWIFT_PROJECT_DOMAIN')) ?: 'Default',
],
],
],
'serviceName' => (getenv('OBJECTSTORE_SWIFT_SERVICE_NAME')) ?: 'swift',
'region' => getenv('OBJECTSTORE_SWIFT_REGION'),
'url' => getenv('OBJECTSTORE_SWIFT_URL'),
'bucket' => getenv('OBJECTSTORE_SWIFT_CONTAINER_NAME'),
]
]
);
}
4 changes: 4 additions & 0 deletions charts/nextcloud-lc/files/upgrade-disable-web.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?php
$CONFIG = array (
'upgrade.disable-web' => true,
);
Binary file added charts/nextcloud-lc/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 6ae7657

Please sign in to comment.