英文:
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 a more elegant way? Is it even possible to install an app in a local environment to test it and later deploy it to production?
英文:
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?
答案1
得分: 3
现在可以使用Composer来安装应用程序,就像使用插件一样。
英文:
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.
答案2
得分: 3
We didn't want 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.
英文:
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.
答案3
得分: 2
只是为了补充一下:虽然你无法使用composer获取应用本身,但你可以自动安装应用。一旦你获得了应用的源文件,你可以将它们部署在 custom/apps
目录下,并通过命令行界面安装应用。
bin/console app:install ExampleApp --activate
英文:
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
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论