Alex
Alex

Reputation: 35008

How to install a Shopware 6 app in a composer-managed installation and deploy process?

We are trying to install the PAQATO app in a self hosted store and normally use composer for installation (for "normal" - non-app - extensions)

Sidenote: We were not able to download the latest version ZIP via https://account.shopware.com/ because of the error "Unable to download version 1.0.2. The version has been revoked by the manufacturer." - we contacted the vendor already.

But: Even if we get a ZIP here, do we have to install it manually via the admin panel, which would probably place it to custom/plugins and commit it to our project GIT to deploy it to testing, staging and so on?

Or is there an more elegant way? Is it even possible to install an app in a local environment to test it and later deploy it to production?

Upvotes: 2

Views: 1216

Answers (3)

Rune Laenen
Rune Laenen

Reputation: 293

At this moment apps cannot be installed through Composer, thus the only way to install them is to add them to the /custom/plugins folder and commit them into your git repository.

Edit: it is now possible to use composer to install apps, in the same way as it is possible with plugins.

Upvotes: 3

Shyim
Shyim

Reputation: 864

We didn't wanted apps on composer as this allows people to lock down on old app versions and app manufacturers have to take care about old versions in their app backend. For this reason is there also a UpdateApps task.

But, with the adoption of themes to apps, we can't really go this way anymore as locking on theme versions is a valid reason.

In the meanwhile (SCUC) i have created an internal issue to index also apps to our composer registry, I can't give any ETA when it will be implemented.

To general apps deployment: When an app has an app backend, you should not copy your live database to staging 1:1. The app backend cannot differentiate between your live and staging server and there can problems happen. Therefore I would recommend to remove all apps from your dump where an app_secret is set in the app table and install them again if needed.

Upvotes: 3

dneustadt
dneustadt

Reputation: 13161

Just to add to this: While you cannot use composer to retrieve the app itself, you may automate the installation of apps. Once you do have the source files of the app you may deploy them in custom/apps and install the app via the CLI.

bin/console app:install ExampleApp --activate

Upvotes: 2

Related Questions