I try fresh install silverstripe4 with postgresql support but installer got error:
Uncaught Exception SilverStripe\Core\Injector\InjectorNotFoundException: “Class PostgreSQLDatabase does not exist” at /var/www/site/vendor/silverstripe/framework/src/Core/Injector/InjectionCreator.php line 13 {“exception”:“[object] (SilverStripe\Core\Injector\InjectorNotFoundException(code: 0): Class PostgreSQLDatabase does not exist at /var/www/site/vendor/silverstripe/framework/src/Core/Injector/InjectionCreator.php:13)”}
Process to install:
cd /var/www
composer create-project silverstripe/installer site
cd site
composer require silverstripe/postgresql
cp .env.example .env
nano .env
See environment variables for more details. Note that a database will automatically be created via dev/build.
But when open env. docs link don’t see how to run deb/build
You can run the dev/build from the browser by just adding it to the end of the URL:
eg:
https://example.com/dev/build?flush
Do you have the site in dev mode? This can be set in your env file:
SS_ENVIRONMENT_TYPE=dev
Dev mode will often show more debug output if the error can be caught. Otherwise, you may need to look in your server logs to see what the new error is.