Skip to content

Commit 3b5ab60

Browse files
committed
Make sure symfony cloud have a database
1 parent 29caf57 commit 3b5ab60

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

.env

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ BOT_USERNAME='carsonbot-test'
3131
# For an SQLite database, use: "sqlite:///%kernel.project_dir%/var/data.db"
3232
# For a PostgreSQL database, use: "postgresql://db_user:[email protected]:5432/db_name?serverVersion=11&charset=utf8"
3333
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml
34-
DATABASE_URL=mysql://db_user:[email protected]:3306/db_name?serverVersion=5.7
34+
#DATABASE_URL=mysql://db_user:[email protected]:3306/db_name?serverVersion=5.7
3535
###< doctrine/doctrine-bundle ###

.symfony.cloud.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ runtime:
66
extensions:
77
- apcu
88
- mbstring
9+
- pdo_pgsql
910

1011
build:
1112
flavor: none
@@ -36,3 +37,6 @@ crons:
3637
run_Tasks:
3738
spec: */5 * * * *
3839
cmd: croncape bin/console app:task:run
40+
41+
relationships:
42+
database: "mydatabase:postgresql"

.symfony/services.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
mydatabase:
2+
# supported versions: 9.6, 10, 11, 12
3+
# 9.3 is also available but not maintained upstream
4+
type: postgresql:12
5+
disk: 1024

0 commit comments

Comments
 (0)