brave-florist-49480
03/11/2021, 1:31 PMhappy-addition-42792
03/11/2021, 1:51 PMconfig_default-X.php
$config[PropelConstants::ZED_DB_HOST] = 'external_host_name_or_ip';polite-lunch-97479
03/11/2021, 1:52 PMbrave-florist-49480
03/11/2021, 2:01 PMbrave-florist-49480
03/11/2021, 2:02 PMpolite-lunch-97479
03/11/2021, 2:02 PM$config[PropelConstants::ZED_DB_ENGINE]
= $config[PropelQueryBuilderConstants::ZED_DB_ENGINE]
= strtolower(getenv('SPRYKER_DB_ENGINE') ?: '') ?: PropelConfig::DB_ENGINE_PGSQL;
$config[PropelConstants::ZED_DB_HOST] = getenv('SPRYKER_DB_HOST');
$config[PropelConstants::ZED_DB_PORT] = getenv('SPRYKER_DB_PORT');
$config[PropelConstants::ZED_DB_USERNAME] = getenv('SPRYKER_DB_USERNAME');
$config[PropelConstants::ZED_DB_PASSWORD] = getenv('SPRYKER_DB_PASSWORD');
$config[PropelConstants::ZED_DB_DATABASE] = getenv('SPRYKER_DB_DATABASE');
$config[PropelConstants::ZED_DB_REPLICAS] = json_decode(getenv('SPRYKER_DB_REPLICAS') ?: '[]', true);
$config[PropelConstants::USE_SUDO_TO_MANAGE_DATABASE] = false;
Env var for user for example is SPRYKER_DB_USERNAME.polite-lunch-97479
03/11/2021, 2:04 PMbrave-florist-49480
03/11/2021, 2:07 PMbrave-florist-49480
03/11/2021, 2:11 PMbrave-florist-49480
03/11/2021, 2:11 PMpolite-lunch-97479
03/11/2021, 2:11 PMdocker/sdk bootstrap deploy.dev.yml
docker/sdk up
Then, you should be able to use your env var values in config_default.php.polite-lunch-97479
03/11/2021, 2:17 PMbrave-florist-49480
03/11/2021, 2:26 PMpolite-lunch-97479
03/11/2021, 2:33 PMsymfony/dotenv.
Then in e. g. config_default do
$dotenv = new Dotenv();
$dotenv->usePutenv();
$dotenv->load(sprintf('%s/../../.env.local', __DIR__));
Then you can get your env vars via getenv() .brave-florist-49480
03/11/2021, 3:15 PMSPRYKER_DB_ENGINE: "DB_ENGINE_PGSQL"
SPRYKER_DB_HOST: "xxxx"
SPRYKER_DB_PORT: "5432"
SPRYKER_DB_USERNAME: "xxxx"
SPRYKER_DB_PASSWORD: "xxxx"
SPRYKER_DB_DATABASE: "postgres"
? in your mention documentation i can't flolow where to put this. Otherwise please show with heading line i need to re-readpolite-lunch-97479
03/11/2021, 3:15 PMbrave-florist-49480
03/11/2021, 3:16 PMbrave-florist-49480
03/11/2021, 3:17 PMRunning generator
PHP Notice: Undefined index: DE in /data/index.php on line 210
PHP Notice: Undefined index: DE in /data/index.php on line 303
PHP Warning: array_replace_recursive(): Expected parameter 1 to be an array, null given in /data/index.php on line 304
PHP Notice: Undefined index: DE in /data/index.php on line 318
PHP Notice: Undefined index: DE in /data/index.php on line 210
PHP Fatal error: Uncaught Twig\Error\LoaderError: Template "env/database/.env.twig" is not defined in "env/application/zed.env.twig" at line 25. in /data/vendor/twig/twig/src/Loader/ChainLoader.php:98
Stack trace:
#0 /data/vendor/twig/twig/src/Environment.php(299): Twig\Loader\ChainLoader->getCacheKey('env/database/.e...')
#1 /data/vendor/twig/twig/src/Environment.php(381): Twig\Environment->getTemplateClass('env/database/.e...')
#2 /data/vendor/twig/twig/src/Template.php(335): Twig\Environment->loadTemplate('env/database/.e...', NULL)
#3 /data/vendor/twig/twig/src/Environment.php(418) : eval()'d code(68): Twig\Template->loadTemplate('env/database/.e...', 'env/application...', 25)
#4 /data/vendor/twig/twig/src/Template.php(407): __TwigTemplate_64e7675df8da3481952f197c98ec39fc33132be6d48b6a901bfbd8429e3ca59d->doDisplay(Array, Array)
#5 /data/vendor/twig/twig/src/Template.php(380): Twig\Template->displayWithErrorHandling(Array, Array)
#6 /data/vendor/twig/twig/src/Template.php(392): Twig\Template->display(Array)
#7 /data/vendor in /data/vendor/twig/twig/src/Loader/ChainLoader.php on line 98polite-lunch-97479
03/11/2021, 3:22 PMbrave-florist-49480
03/11/2021, 3:28 PMbrave-florist-49480
03/12/2021, 9:28 AMbrave-florist-49480
03/12/2021, 9:28 AMbrave-florist-49480
03/12/2021, 9:29 AMpolite-lunch-97479
03/12/2021, 10:28 AMhappy-addition-42792
03/12/2021, 10:40 AMbrave-florist-49480
03/12/2021, 12:39 PMhigh-pencil-62400
03/12/2021, 8:45 PM