Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/CleverCloud/laravel-postgresql-example
Run Laravel with PostgreSQL on Clever Cloud
https://github.com/CleverCloud/laravel-postgresql-example
clevercloud-example laravel postgresql
Last synced: 2 months ago
JSON representation
Run Laravel with PostgreSQL on Clever Cloud
- Host: GitHub
- URL: https://github.com/CleverCloud/laravel-postgresql-example
- Owner: CleverCloud
- Created: 2017-07-12T09:41:49.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2020-03-17T09:54:59.000Z (almost 5 years ago)
- Last Synced: 2024-08-04T17:08:48.800Z (6 months ago)
- Topics: clevercloud-example, laravel, postgresql
- Language: JavaScript
- Homepage:
- Size: 940 KB
- Stars: 0
- Watchers: 16
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
- awesome-clever-cloud - demo-laravel-pg
README
# Laravel as Clever Cloud demo
This sample project is a fork from [GitHub](https://github.com/evercode1/sample-project).
## Configuration
To use a database (like PostgreSQL), you can link your application with an addon or manually set the following environment variables will be set.
```bash
POSTGRESQL_ADDON_HOST
POSTGRESQL_ADDON_PORT
POSTGRESQL_ADDON_DB
POSTGRESQL_ADDON_USER
POSTGRESQL_ADDON_PASSWORD
```To update your database schema, add this environment variable to your Clever Cloud application:
```bash
CC_POST_BUILD_HOOK=php artisan migrate --force
```To enable logs retrieving on Clever console or Clever CLI, ensure that you have the following value in `./config/app.php`:
```php
'log' => env('APP_LOG'),
```Then you can create a Clever application environment variable as following: `APP_LOG=syslog`.
Finally, you have to manually set the `APP_KEY=base64:X` with `X` the result of `php artisan key:generate` on your local project.