Deploying Rocket
Github Pages
The Rocket Starter ships with GitHub Pages integration set up by default. You will find the file at
my-project
├── .github
│ └── workflows
│ └── github-build-and-deploy-rocket-action.yml
├── site/*
└── package.json
This means to go live with a freshly created Rocket project hosted on GitHub you need to change the Repository's Settings following these steps:
- After pushing your generated Rocket project to GitHub, navigate to the
Settings
-tab in your repository. - From this tab, select the side navigation option
Pages
. - In your
Pages
-page, set theSource
option to the newly generatedgh-pages
-branch, leaving the directory as/ (root)
. - Save your Settings.
And you're done!
Your page should now appear hosted in https://yourusername.github.io/your-repository/
in the following minutes.
You won't need to worry about any deployments either. Rocket will automatically handle deployments from your main branch onto the newly published GitHub pages every time you push your code.