Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add shopware/app-bundle 4.0 variant #1673

Merged
merged 1 commit into from
Sep 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions shopware/app-bundle/4.0/config/packages/shopware_app.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
shopware_app:
name: '%env(SHOPWARE_APP_NAME)%'
secret: '%env(SHOPWARE_APP_SECRET)%'
# You should use doctrine or dynamodb as storage
storage: 'in-memory'
doctrine:
shop_class: App\Entity\Shop
8 changes: 8 additions & 0 deletions shopware/app-bundle/4.0/config/routes/shopware_app.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
shopware_app_lifecycle:
resource: '@ShopwareAppBundle/Resources/config/routing/lifecycle.xml'
prefix: /app

shopware_app_webhook:
resource: '@ShopwareAppBundle/Resources/config/routing/webhook.xml'
prefix: /app

13 changes: 13 additions & 0 deletions shopware/app-bundle/4.0/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"bundles": {
"Shopware\\AppBundle\\ShopwareAppBundle": ["all"]
},
"copy-from-recipe": {
"config/": "%CONFIG_DIR%/",
"src/": "%SRC_DIR%/"
},
"env": {
"SHOPWARE_APP_NAME": "TestApp",
"SHOPWARE_APP_SECRET": "MySecret"
}
}
6 changes: 6 additions & 0 deletions shopware/app-bundle/4.0/post-install.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
* <fg=yellow>Warning</> the shopware/app-bundle uses by default a in-memory database. You should use doctrine or dynamodb

For doctrine install the following packages: composer require doctrine/orm symfony/doctrine-bridge
For dynamodb install the following packages: composer require async-aws/async-aws-bundle async-aws/dynamo-db

Make sure to configure the correct storage after installing the packages in config/packages/shopware_app.yaml
13 changes: 13 additions & 0 deletions shopware/app-bundle/4.0/src/Entity/Shop.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace App\Entity;

use Doctrine\ORM\Mapping\Entity;
use Shopware\AppBundle\Entity\AbstractShop;

#[Entity]
class Shop extends AbstractShop
{
}
Loading