gpt4 book ai didi

wordpress - 在 Heroku 上部署 WordPress?

转载 作者:行者123 更新时间:2023-12-02 03:16:33 27 4
gpt4 key购买 nike

我正在尝试在 Heroku 上部署 WordPress,出现错误,并且我遇到了更新和安装插件或主题的问题,应该在本地完成,然后推送到 Heroku。那么媒体(图片和视频)又如何

  remote:  !     WARNING: No 'composer.json' found!
remote: !
remote: ! Your project only contains an 'index.php', no 'composer.json'.
remote: !
remote: ! Using 'index.php' to declare app type as PHP is deprecated and
remote: ! may lead to unexpected behavior.
remote: !
remote: ! Please consider updating your codebase to utilize Composer and
remote: ! modern dependency management in order to benefit from the latest
remote: ! PHP runtimes and improved application performance, as well as
remote: ! control over the PHP versions and extensions available.
remote: !
remote: ! For an introduction to dependency management with Composer and
remote: ! how to get the most out of PHP on Heroku, refer to the docs at
remote: ! https://getcomposer.org/doc/00-intro.md and
remote: ! https://devcenter.heroku.com/articles/getting-started-with-php
remote:

最佳答案

要部署任何基于 PHP 的应用程序 CMS/FW,您需要在根目录添加 composer.json,因为 Heroku 默认将运行 Composer 安装。

因此,只需在根目录中添加不带任何依赖项的composer.json(与 wp-config 相同的级别)即可完美运行

关于wordpress - 在 Heroku 上部署 WordPress?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55979339/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com