mirror of
https://github.com/nextcloud/docker.git
synced 2025-03-16 11:25:09 +01:00
Add default values for reverse proxy config from environment
Signed-off-by: András Maróy <andras@maroy.hu>
This commit is contained in:
parent
a41ef6143d
commit
2b2bd3c6aa
10 changed files with 100 additions and 0 deletions
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
|
@ -1,20 +1,30 @@
|
|||
<?php
|
||||
if (getenv('OVERWRITEHOST')) {
|
||||
$CONFIG['overwritehost'] = getenv('OVERWRITEHOST');
|
||||
} else {
|
||||
$CONFIG['overwritehost'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEPROTOCOL')) {
|
||||
$CONFIG['overwriteprotocol'] = getenv('OVERWRITEPROTOCOL');
|
||||
} else {
|
||||
$CONFIG['overwriteprotocol'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITEWEBROOT')) {
|
||||
$CONFIG['overwritewebroot'] = getenv('OVERWRITEWEBROOT');
|
||||
} else {
|
||||
$CONFIG['overwritewebroot'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OVERWRITECONDADDR')) {
|
||||
$CONFIG['overwritecondaddr'] = getenv('OVERWRITECONDADDR');
|
||||
} else {
|
||||
$CONFIG['overwritecondaddr'] = '';
|
||||
}
|
||||
|
||||
if (getenv('TRUSTED_PROXIES')) {
|
||||
$CONFIG['trusted_proxies'] = explode(',', getenv('TRUSTED_PROXIES'));
|
||||
} else {
|
||||
$CONFIG['trusted_proxies'] = [];
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue