Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Database connection [postgres] not configured. #68

Open
thiagoalmeida88 opened this issue Feb 21, 2022 · 0 comments
Open

Database connection [postgres] not configured. #68

thiagoalmeida88 opened this issue Feb 21, 2022 · 0 comments

Comments

@thiagoalmeida88
Copy link

When deploying with PHP 7.4 on AL2 current version 3.3.10, it is giving this problem related to composer install. In version 3.3.9 this does not happen. Is there any way around this?

2022/02/18 20:32:08.174278 [INFO] Executing instruction: StageApplication
2022/02/18 20:32:08.622477 [INFO] extracting /opt/elasticbeanstalk/deployment/app_source_bundle to /var/app/staging/
2022/02/18 20:32:08.622505 [INFO] Running command /bin/sh -c /usr/bin/unzip -q -o /opt/elasticbeanstalk/deployment/app_source_bundle -d /var/app/staging/
2022/02/18 20:32:08.682970 [INFO] finished extracting /opt/elasticbeanstalk/deployment/app_source_bundle to /var/app/staging/ successfully
2022/02/18 20:32:08.688830 [INFO] Executing instruction: RunAppDeployPreBuildHooks
2022/02/18 20:32:08.688850 [INFO] Executing platform hooks in .platform/hooks/prebuild/
2022/02/18 20:32:08.688914 [INFO] Following scripts will be executed in order: [configure_php_ini.sh update_composer.sh]
2022/02/18 20:32:08.688920 [INFO] Running script: .platform/hooks/prebuild/configure_php_ini.sh
2022/02/18 20:32:08.706856 [INFO] Running script: .platform/hooks/prebuild/update_composer.sh
2022/02/18 20:32:09.061395 [INFO] Finished running scripts in /var/app/staging/.platform/hooks/prebuild
2022/02/18 20:32:09.061416 [INFO] Executing instruction: Install composer dependencies
2022/02/18 20:32:09.061430 [INFO] installing composer dependencies...
2022/02/18 20:32:09.061451 [INFO] Running command /bin/sh -c composer.phar install --no-ansi --no-interaction
2022/02/18 20:32:14.559337 [INFO]
InvalidArgumentException

Database connection [postgres] not configured.

at vendor/laravel/framework/src/Illuminate/Database/DatabaseManager.php:152
148| // If the configuration doesn't exist, we'll throw an exception and bail.
149| $connections = $this->app['config']['database.connections'];
150|
151| if (is_null($config = Arr::get($connections, $name))) {

152| throw new InvalidArgumentException("Database connection [{$name}] not configured.");
153| }
154|
155| return (new ConfigurationUrlParser)
156| ->parseConfiguration($config);

  �[2m+9 vendor frames �[22m

10 app/Services/NewService.php:23
Illuminate\Database\Eloquent\Model::query()

11 [internal]:0
App\Services\NewService::__construct(Object(App\Services\FileService), Object(App\Models\Administrator))

2022/02/18 20:32:14.559391 [ERROR] An error occurred during execution of command [app-deploy] - [Install composer dependencies]. Stop running the command. Error: installing composer dependencies failed with error: Command /bin/sh -c composer.phar install --no-ansi --no-interaction failed with error exit status 1. Stderr:Do not run Composer as root/super user! See https://getcomposer.org/root for details

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant