Laravel 4以及使用FTP部署应用程序的方式 [英] Laravel 4 and the way to deploy app using FTP

查看:94
本文介绍了Laravel 4以及使用FTP部署应用程序的方式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我使用Composer在本地开发了我的应用程序。



现在,我已准备好将此应用程序部署到生产环境中。



我有(目前)只使用FTP的生产服务器。 。



我已阅读此论坛:
Laravel论坛



但我认为这是不正确的。

我在服务器上创建了一个目录,例如: http://wwww.myserver.com/app

在/ app目录中,我复制了(通过FTP)我的所有文件...

但这不是工作..我必须改变一些东西?

解决方案

假设您的文档。根文件夹为www


  1. 在您的共享主机上(在www之外)创建一个名为laravel的文件夹,并将您的应用程序结构上传到此文件夹公共文件夹。

  2. 将公用文件夹的内容上传到www文件夹中。 调整bootstrap / paths.php文件中的路径结构
  3. li>
  4. 还要更改www / index.php文件中的路径以找到新的laravel文件夹。

  5. 完成。

在下面的文章中还有另外两个解决方案(以及我的更详细的解决方案):

http://driesvints.com/blog/laravel-4-on-a-shared-host


I have a question about the way used to deploy a Laravel Application.

I have developed my application locally using Composer.

Now, I'm ready to deploy this application to the production.

I have (at the moment) a production server that use only FTP..

I have read this forum: Laravel Forum

but I think that this is not correct..

I have created a directory on my server for example: http://wwww.myserver.com/app

In the /app directory I copied (by FTP) all my files...

But this not work..I have to change something?

解决方案

Let's say your doc. root folder is www

  1. Create a folder called laravel on your shared hosting (outside of www) and upload your application structure to this folder, except the public folder.
  2. Upload your public folder's content into the www folder
  3. Adjust the path structure in the bootstrap/paths.php file.
  4. Also change the paths in the www/index.php file to locate the new laravel folder.
  5. Done.

There are 2 more solutions (and my one in more detailed as well) in the following article as well:

http://driesvints.com/blog/laravel-4-on-a-shared-host

这篇关于Laravel 4以及使用FTP部署应用程序的方式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆