Skip to content

Commit 7c9191c

Browse files
committed
Add recipe for platformsh-meta
1 parent b6554d7 commit 7c9191c

File tree

7 files changed

+108
-0
lines changed

7 files changed

+108
-0
lines changed
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: app
2+
3+
type: php:8.0
4+
5+
runtime:
6+
extensions:
7+
- apcu
8+
- mbstring
9+
- sodium
10+
- ctype
11+
- iconv
12+
- xsl
13+
- pdo_pgsql
14+
- blackfire
15+
16+
variables:
17+
php:
18+
opcache.preload: /app/config/preload.php
19+
20+
build:
21+
flavor: none
22+
23+
disk: 512
24+
25+
relationships:
26+
database: "database:postgresql"
27+
28+
web:
29+
locations:
30+
"/":
31+
root: "public"
32+
expires: 1h
33+
passthru: "/index.php"
34+
35+
mounts:
36+
"/var": { source: local, source_path: var }
37+
38+
hooks:
39+
build: |
40+
set -x -e
41+
42+
curl -fs https://get.symfony.com/cloud/configurator | (>&2 bash)
43+
44+
(>&2 symfony-build)
45+
46+
deploy: |
47+
set -x -e
48+
49+
(>&2 symfony-deploy)
50+
51+
workers:
52+
messenger:
53+
# PHP background workers usually don't require much CPU.
54+
# See https://symfony.com/doc/current/cloud/cookbooks/resources_allocation.html
55+
size: XS
56+
resources:
57+
base_memory: 64 # Keep in sync with the `memory-limit` flag value
58+
memory_ratio: 128
59+
commands:
60+
# Don't forget to update your receiver name(s)
61+
start: symfony console --time-limit=3600 --memory-limit=64M messenger:consume async
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
"https://{all}/": { type: upstream, upstream: "app:http" }
2+
"http://{all}/": { type: redirect, to: "https://{all}/" }
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
database:
2+
type: postgresql:13
3+
disk: 1024
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
framework:
2+
messenger:
3+
failure_transport: failed
4+
5+
transports:
6+
# https://symfony.com/doc/current/messenger.html#transport-configuration
7+
async:
8+
dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
9+
options:
10+
use_notify: true
11+
check_delayed_interval: 60000
12+
retry_strategy:
13+
max_retries: 3
14+
multiplier: 2
15+
failed: 'doctrine://default?queue_name=failed'
16+
# sync: 'sync://'
17+
18+
routing:
19+
# Route your messages to the transports
20+
# 'App\Message\YourMessage': async
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"copy-from-recipe": {
3+
"config/": "%CONFIG_DIR%/",
4+
".platform/": ".platform/",
5+
".platform.app.yaml": ".platform.app.yaml",
6+
"php.ini": "php.ini"
7+
},
8+
"env": {
9+
"MESSENGER_TRANSPORT_DSN": "doctrine://default"
10+
}
11+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
allow_url_include=off
2+
assert.active=off
3+
display_errors=off
4+
display_startup_errors=off
5+
max_execution_time=30
6+
session.use_strict_mode=On
7+
realpath_cache_ttl=3600
8+
zend.detect_unicode=Off
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"aliases": ["platformsh"]
3+
}

0 commit comments

Comments
 (0)