1
0
Fork 0
mirror of synced 2024-05-20 20:52:36 +12:00

Updated domain setting

This commit is contained in:
eldadfux 2019-11-21 20:28:15 +02:00
parent 81d3a81e91
commit ec89ff0ca8
2 changed files with 8 additions and 6 deletions

View file

@ -43,15 +43,17 @@ $collections = include __DIR__.'/../app/config/collections.php'; // OAuth provid
$redisHost = $request->getServer('_APP_REDIS_HOST', '');
$redisPort = $request->getServer('_APP_REDIS_PORT', '');
$utopia = new App('Asia/Tel_Aviv', $env);
$port = (string) (isset($_SERVER['HTTP_HOST'])) ? parse_url($_SERVER['HTTP_HOST'], PHP_URL_PORT) : '';
$port = (string) parse_url($request->getServer('HTTP_HOST', ''), PHP_URL_PORT);
Resque::setBackend($redisHost.':'.$redisPort);
define('COOKIE_DOMAIN', (
$request->getServer('HTTP_HOST', null) === 'localhost' ||
$request->getServer('HTTP_HOST', null) === 'localhost:'.$port)
define('COOKIE_DOMAIN',
(
$request->getServer('HTTP_HOST', null) === 'localhost' ||
$request->getServer('HTTP_HOST', null) === 'localhost:'.$port
)
? null
: '.'.parse_url($request->getServer('HTTP_HOST', false), PHP_URL_HOST));
: '.'.parse_url($request->getServer('HTTP_HOST', ''), PHP_URL_HOST));
define('COOKIE_SAMESITE', null); // Response::COOKIE_SAMESITE_NONE
/*

View file

@ -1,4 +1,4 @@
# Generated by pub on 2019-11-20 21:18:37.276237.
# Generated by pub on 2019-11-21 20:19:20.138749.
charcode:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/charcode-1.1.2/lib/
collection:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/collection-1.14.12/lib/
cookie_jar:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/cookie_jar-1.0.1/lib/