Laravel Shared Hosting
Laravel is not suited for Shared Hosting Servers. However it is possible according an article on Laravel Article [1]
This article focuses on the shared hosting on One Hosting [2]
Introduction
Shared hosting is very popular (Budget hosting), but will not provide the user from ssh access. On One you have ssh access, but the possibility of running commands is limited.
Welcome on the One.com SSH service This service offers an environment for you to interact with your files in your web space, either directly using your shell, or by using secure file transfer protocols such as SFTP, SCP, RSYNC over SSH. ...
So you can not deploy or run artisan commands like php artisan serve.
Deployment Steps
- Remove the public from the URL.
- Export database from the local environment.
- Do ZIP your Laravel project.
- Create a database in your cPanel.
- Import the local exported database into a shared hosting database.
- Upload project ZIP file to public_html folder and extract.
- Update database details into the config file.
- Some security setup.
Remove Public
Export Database
ZIP or SFTP Files
See also
Reference
- ↑ https://laravelarticle.com/deploy-laravel-on-shared-hosting LaravelArticle], Deploy Laravel on shared hosting.
- ↑ One.com, Shared Hosting Provider.