Git deployment on Flashcloud shared plans works on a pull-only model. Because shell access is turned off on the Start plan, the server does not give you an incoming Git clone URL, and you cannot run git push directly to your hosting account from your local machine. Instead, cPanel pulls commits over HTTPS from a public GitHub repository down to the server.
To put files live, you must include a valid .cpanel.yml file in your repository root, commit your finished production files, pull the changes in cPanel, and click the deployment trigger. This guide covers how to set up this workflow and avoid common deployment failures.
The pull-only workflow and built assets
The Git integration in cPanel acts as a remote working copy, not a continuous integration pipeline. The server does not run build scripts such as npm run build, composer install, or static site bundlers when you pull code. It strictly moves repository files into your working folders.
If your project relies on compiled assets (such as React, Vite, Vue, or Hugo), you must build your production assets locally or in GitHub Actions before deploying. Commit the built output directly to your branch, or push the compiled files to a dedicated release branch on GitHub. What you pull into cPanel must already be servable by LiteSpeed.
For more architectural context on hosting repositories, see our guide to Git Version Control in cPanel: create and clone repos and the broader overview of Deploying with Git.
Set up .cpanel.yml in your repository
cPanel uses a YAML file named .cpanel.yml located in the root of your repository to understand where your files should go. Without this file, cPanel will download your commits into a storage directory on the server, but it will never copy them to the web root where visitors can see them.
Create a file named .cpanel.yml in your repository root. The syntax must look like this:
---
deployment:
tasks:
- export DEPLOYPATH=/home/username/public_html/
- /bin/cp index.html $DEPLOYPATH
- /bin/cp -R css/ $DEPLOYPATH
- /bin/cp -R js/ $DEPLOYPATH
Replace username with your actual cPanel username. Adjust the target path based on the domain you are deploying:
- Main website: The web root is
/home/username/public_html/. - Subdomains: On Flashcloud, a subdomain document root is located at
/home/username/subdomain/(a folder sitting next topublic_html, not inside it).
You can also copy an entire folder of built files. For example, if your repository contains a production folder named dist/, your tasks can copy the contents of that folder straight to your deployment path:
---
deployment:
tasks:
- export DEPLOYPATH=/home/username/public_html/
- /bin/cp -R dist/* $DEPLOYPATH
Commit this file to GitHub. The branch must stay clean. If there are syntax errors or missing paths in .cpanel.yml, the deployment action in cPanel will fail.
Clone your GitHub repo in cPanel
Once your repository contains your site files and .cpanel.yml, clone it through the cPanel interface:
- Log in to the Flashcloud portal at
portal.flashcloud.com. - Navigate to Services, select your hosting plan, and click the cPanel one-click login tile.
- Under the Files section, open Git Version Control. (If you use the Meridian theme, you can use the top search bar to open it).
- Click the Create button on the right.
- Leave the Clone a Repository toggle enabled.
- Paste the HTTPS URL of your public GitHub repository into the Clone URL field (for example,
https://github.com/account/project.git). - The form automatically fills the Repository Path and Repository Name fields based on the URL. Leave the repository path outside of your public directory (for example,
repositories/project). Storing the repository outside the document root ensures your Git history, configuration files, and.cpanel.ymlare never exposed over the web. - Click Create.
cPanel will clone the repository from GitHub into the designated server directory. Small repositories land in moments; large ones take longer, and the list refreshes when the clone is done.
Pull updates and trigger deployment
Because the server does not listen for incoming pushes, you must update your files whenever you push a new commit to GitHub:
- Open Git Version Control in cPanel.
- Find your repository in the list and click Manage.
- Switch to the Pull or Deploy tab.
- Under the Update from Remote heading, click Update from Remote. This pulls the latest commits from your GitHub branch into the repository copy on the server.
- Once the pull completes successfully, scroll to the Deploy HEAD Commit heading and click Deploy HEAD Commit.
Clicking Deploy HEAD Commit executes the commands listed in your .cpanel.yml file. If the file is valid, your latest assets will copy into your document root immediately.
Troubleshooting deployment issues
If your files do not update on the live site, check these points:
- Disabled "Deploy HEAD Commit" button: cPanel disables this button if it cannot find
.cpanel.ymlin the root of the pulled branch, or if there is a syntax error in the YAML formatting. Verify that your YAML indentation uses standard spaces, not tabs. - Uncommitted changes: The "Deploy HEAD Commit" action requires a clean branch. If server-side processes edited or created untracked files in the repository path, cPanel will prevent updates to avoid overwriting them.
- Wrong destination path: Confirm whether you deployed to
public_html/or a subdomain directory. Remember that subdomains sit parallel topublic_html, not inside it. - Private repositories: Without shell access on shared plans, cPanel cannot establish SSH authentication prompts for private repositories. The clone URL must be public over HTTPS.
- LiteSpeed caching: If files copied successfully but your browser shows older content, open your portal dashboard, go to Services, and review your caching settings, or purge the cache through your application.
If the deployment log reports command errors that you cannot resolve, open a ticket through the portal by going to Support → New ticket. Our support team can review file permissions and help identify path issues on your account.