简体   繁体   English

如何在实时服务器cpanel上安装composer以使本地安装的库在实时环境下工作

[英]How to install composer on live server cpanel to make local installed library work on live

I uploaded my yii1 project to live server,there was a library (which I have installed it on local machine using composer) give an error ( class not found ), what I did was: 我将yii1项目上传到实时服务器,有一个库(我已使用composer将其安装在本地计算机上)给出了错误( class not found ),我所做的是:

  1. Ensure that in my file access to autoload file in library correctly. 确保在我的文件中正确访问自动加载库中的文件。
  2. Contacting with support team of hosting company to install composer on the server, they replied "you have to use dedicated server or vps to complete this action". 与托管公司的支持团队联系以在服务器上安装composer,他们回答“您必须使用专用服务器或vps才能完成此操作”。

(The library is a client library for LinkedIn). (该库是LinkedIn的客户端库)。

Should I install composer using ssh protocol on the server? 我应该在服务器上使用ssh协议安装composer吗? Or is there another solution? 还是有其他解决方案?

I uploaded my yii1 project to live server 我将yii1项目上传到实时服务器

But not including all dependencies... 但不包括所有依赖项...

The unresolved or missing dependency just indicates that you didn't resolve the dependencies correctly before deployment or that the packaging wasn't including the dependency. 未解决或丢失的依赖项仅表示您在部署之前未正确解决依赖项,或者包装中未包含该依赖项。

Should I install composer using ssh protocol on the server? 我应该在服务器上使用ssh协议安装composer吗? Or is there another solution? 还是有其他解决方案?

You don't need Composer on the production machine at all. 您完全不需要生产机器上的Composer。

Solution: Package your application completely including all dependencies. 解决方案:完全打包您的应用程序,包括所有依赖项。

Please resolve all Composer dependencies, so that the app runs in the development/packaging stage. 请解决所有Composer依赖项,以便该应用程序在开发/打包阶段运行。 Package correctly, then deploy. 正确打包,然后部署。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在实时服务器cpanel中安装composer - How can I install composer in live server cpanel 如何使实时服务器Ratchet WebSockets工作? - How to make live server Ratchet WebSockets work? 如何在服务器面板上运行composer安装 - how to run composer install on the server cpanel Laravel-在实时服务器上安装与Composer一起安装的软件包 - Laravel - Installing packages that were installed with composer on live server 可在本地(MAMP)和实时服务器上使用的绝对URL - Absolute URLs that will work on local (MAMP) and live server 如何在实时网站中使用Composer安装PHRETS 2.0。 - How to install PHRETS 2.0 using Composer in live website. 简单的 Html Dom 库适用于本地服务器,但不适用于大多数实时服务器 - Simple Html Dom library works on local server but not in mostly live server 如何在实时服务器中安装phpSHIELD加载程序? - How to Install phpSHIELD loader in live server? 实时服务器中的 PHP Cookies 不工作但在本地主机中工作 - PHP Cookies in live server do not work but work in Local Host CORS Ajax POST变量在实时服务器中为空,但在本地服务器中工作 - CORS Ajax POST variables empty in live server but work in local server
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM