I have been experimenting out how to improve the CPanel experience for Laravel developers and I have been successful a few times. First, We need to make sure that our cPanel has SSH enabled and connected to the GitHub account where we pushed the Laravel project.

Copy the following BASH contents into the deploy.sh: Replace /path/to/project with the path your Laravel application on CPanel.

Copy the following YAML contents into the ci.yml: Replace cpanel_username with your CPanel username and project_dir with your deployed application directory on CPanel.

If you have frontend assets that needs to be built and deployed on cPanel, you can do that also with GitHub Actions.
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge. Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge.
Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Shirts painstakingly handcrafted by under-caffeinated developers. Shirts painstakingly handcrafted by under-caffeinated developers.
Community Partners