在共享主机中仅使用FTP部署Laravel 5 [英] Deploy Laravel 5 using only FTP in a shared hosting

查看:171
本文介绍了在共享主机中仅使用FTP部署Laravel 5的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我的客户端的计划是基本托管:Linux + MySql没有cpanel或类似的(即没有管理员面板)。



我只能通过ftp访问,并且只能访问名为www.mycustomerweb.com的文件夹。这意味着我无法在www.mycustomerweb.com文件夹的同一级别创建目录。



一年前,我部署了一个使用Laravel 4制作的项目:


  1. 摆脱了将其内容移动到根文件夹并更新index.php和bootstrap.php的公共文件夹并更新index.php和bootstrap.php
  2. 完成整个项目localhost(与Xampp)

  3. 通过ftp将所有文件上传到www.myclientweb.com。 >我的问题是:


    1. 我用laravel 4项目做所有事情吗?我可能陷入了安全问题(我的意思是说,网站安全)?

    2. 如何将laravel 5项目部署到同一站点?在Laravel 5中,我无法像使用Laravel 4一样删除公共文件夹。


    现在,我拥有在本地主机上安装Laravel 5,然后通过ftp将所有文件上传到www.myclientweb.com文件夹中:可以在 http://www.myclientweb.com/public 上看到laravel的精彩页面。


  4. 我无法在 http://www.myclientweb.com/ 看到任何内容

  5. 而且我也可以在 http://www.myclientweb.com/.env 上看到.env内容。?????? ?



  6. 当然这不是正确的方法...



    我有一个很长的搜索,通过网络和Stackoverflow没有运气。



    真的很有帮助。
    $ b

    谢谢阅读。

    解决方案

    L4和L5之间没有区别,所以您对L4做了同样的事情。


    I need to deploy a laravel 5 project to a client host.

    The plan of my client is basic hosting: Linux + MySql without cpanel or similar (i.e. no admin panel).

    I have access only via ftp and only to a folder named www.mycustomerweb.com. It means I can not create a directory at the same level of www.mycustomerweb.com folder. Only inside it (I think it is called shared hosting).

    One year ago, I deployed a project made with Laravel 4 this way:

    1. got rid of public folder moving its content to root folder and updating index.php and bootstrap.php
    2. finished whole project in localhost (with Xampp)
    3. uploaded all files to www.myclientweb.com via ftp.

    My questions are:

    1. Did I do everything all right with laravel 4 project? May I have fallen into security issues (I mean, is the site safe)?

    2. How do I deploy a laravel 5 project to the same site? In Laravel 5 I can not get rid of public folder as I did with Laravel 4.

    Right now, I have set up a fresh installation of Laravel 5 on localhost and then I have uploaded all files to www.myclientweb.com folder via ftp:

    Surely this is not the right way...

    I've had a long searching through the web and Stackoverflow with no luck.

    Really apprecite any help.

    Thanks for reading.

    解决方案

    There is no difference between L4 and L5, so do the same thing you did for L4.

    这篇关于在共享主机中仅使用FTP部署Laravel 5的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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