-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add resource package on test application
- Loading branch information
Showing
17 changed files
with
226 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,3 +18,13 @@ | |
APP_ENV=dev | ||
APP_SECRET=28de35e787e86cb435f0312627623283 | ||
###< symfony/framework-bundle ### | ||
|
||
###> doctrine/doctrine-bundle ### | ||
# Format described at https://www.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url | ||
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml | ||
# | ||
# DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db" | ||
# DATABASE_URL="mysql://app:[email protected]:3306/app?serverVersion=8.0.32&charset=utf8mb4" | ||
# DATABASE_URL="mysql://app:[email protected]:3306/app?serverVersion=10.11.2-MariaDB&charset=utf8mb4" | ||
DATABASE_URL="postgresql://app:[email protected]:5432/app?serverVersion=16&charset=utf8" | ||
###< doctrine/doctrine-bundle ### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
services: | ||
###> doctrine/doctrine-bundle ### | ||
database: | ||
ports: | ||
- "5432:5432" | ||
###< doctrine/doctrine-bundle ### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
services: | ||
###> doctrine/doctrine-bundle ### | ||
database: | ||
image: postgres:${POSTGRES_VERSION:-16}-alpine | ||
environment: | ||
POSTGRES_DB: ${POSTGRES_DB:-sylius_stack} | ||
# You should definitely change the password in production | ||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-sylius_stack} | ||
POSTGRES_USER: ${POSTGRES_USER:-sylius_stack} | ||
volumes: | ||
- database_data:/var/lib/postgresql/data:rw | ||
# You may use a bind-mounted host directory instead, so that it is harder to accidentally remove the volume and lose all your data! | ||
# - ./docker/db/data:/var/lib/postgresql/data:rw | ||
###< doctrine/doctrine-bundle ### | ||
|
||
volumes: | ||
###> doctrine/doctrine-bundle ### | ||
database_data: | ||
###< doctrine/doctrine-bundle ### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
doctrine: | ||
dbal: | ||
url: '%env(resolve:DATABASE_URL)%' | ||
|
||
# IMPORTANT: You MUST configure your server version, | ||
# either here or in the DATABASE_URL env var (see .env file) | ||
#server_version: '16' | ||
|
||
profiling_collect_backtrace: '%kernel.debug%' | ||
use_savepoints: true | ||
orm: | ||
auto_generate_proxy_classes: true | ||
enable_lazy_ghost_objects: true | ||
report_fields_where_declared: true | ||
validate_xml_mapping: true | ||
naming_strategy: doctrine.orm.naming_strategy.underscore_number_aware | ||
auto_mapping: true | ||
mappings: | ||
App: | ||
type: attribute | ||
is_bundle: false | ||
dir: '%kernel.project_dir%/app/Entity' | ||
prefix: 'App\Entity' | ||
alias: App | ||
|
||
when@test: | ||
doctrine: | ||
dbal: | ||
# "TEST_TOKEN" is typically set by ParaTest | ||
dbname_suffix: '_test%env(default::TEST_TOKEN)%' | ||
|
||
when@prod: | ||
doctrine: | ||
orm: | ||
auto_generate_proxy_classes: false | ||
proxy_dir: '%kernel.build_dir%/doctrine/orm/Proxies' | ||
query_cache_driver: | ||
type: pool | ||
pool: doctrine.system_cache_pool | ||
result_cache_driver: | ||
type: pool | ||
pool: doctrine.result_cache_pool | ||
|
||
framework: | ||
cache: | ||
pools: | ||
doctrine.result_cache_pool: | ||
adapter: cache.app | ||
doctrine.system_cache_pool: | ||
adapter: cache.system |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
doctrine_migrations: | ||
migrations_paths: | ||
# namespace is arbitrary but should be different from App\Migrations | ||
# as migrations classes should NOT be autoloaded | ||
'DoctrineMigrations': '%kernel.project_dir%/migrations' | ||
enable_profiler: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# @see https://github.com/Sylius/SyliusResourceBundle/blob/master/docs/index.md | ||
sylius_resource: | ||
# Override default settings | ||
#settings: | ||
|
||
# Configure the mapping for your resources | ||
mapping: | ||
paths: | ||
- '%kernel.project_dir%/app/Entity' | ||
|
||
# Configure your resources | ||
resources: | ||
#app.book: | ||
#classes: | ||
#model: App\Entity\Book |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
framework: | ||
validation: | ||
# Enables validator auto-mapping support. | ||
# For instance, basic validation constraints will be inferred from Doctrine's metadata. | ||
#auto_mapping: | ||
# App\Entity\: [] | ||
|
||
when@test: | ||
framework: | ||
validation: | ||
not_compromised_password: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
sylius_crud_routes: | ||
resource: 'sylius.routing.loader.crud_routes_attributes' | ||
type: service | ||
|
||
sylius_routes: | ||
resource: 'sylius.routing.loader.routes_attributes' | ||
type: service |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters