Move laravel project to new server

北城以北 提交于 2020-02-05 13:55:35

问题



I have an existing laravel (v4) project in one server. Now I want to upload it to a new server. Can anyone explain the steps how to do this?

I am very new in Laravel. This is what I have done so far:
I have downloaded all the files to my machine and then uploaded to my new cPanel server. Created mysql database and imported tables.


回答1:


Follow the following steps:

  1. Create a new database from phpmyadmin of your new cpanel
  2. Import your previous database to the new database
  3. In app/config/database.php change your data config to new database configure
  4. Just transfer all your files and folder to new cpanel

If the paths are not changed then your website should work fine.




回答2:


You should add to new server db, dump your db in past server, after add in new server with php my admin, change db configs in application configuration.



来源:https://stackoverflow.com/questions/32696893/move-laravel-project-to-new-server

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!