Skip to content

Latest commit

 

History

History
95 lines (66 loc) · 3.65 KB

github-pages-deployment.md

File metadata and controls

95 lines (66 loc) · 3.65 KB

Deploy static sites to GitHub Pages

The goal of this exercice is to deploy a static website (only HTML, JavaScript and CSS) on GitHub Pages, a static site hosting service, instead of your own server in the Infrastructure-as-a-Service (IaaS) Microsoft Azure Web Services cloud.

Legend

Parts of this guide are annotated with the following icons:

  • ❗ A task you MUST perform to complete the exercise.
  • ❓ An optional step that you may perform to make sure that everything is working correctly.
  • ⚠️ Critically important information about the exercise.
  • 💎 Tips on the exercise, reminders about previous exercises, or explanations about how this exercise differs from the previous one.
  • 👾 More advanced tips on how to save some time. Challenges.
  • 📚 Additional information about the exercise or the commands and tools used.
  • 🏁 The end of the exercise.
    • 🏛️ The architecture of what you deployed during the exercise.
  • 💥 Troubleshooting tips: how to fix common problems you might encounter.

❗ Fork the clock project

Fork the static clock website repository:

Fork the static clock repository

Fork the static clock repository

Once that is done, you should have your own copy of the clock repository under your GitHub username:

Your fork of the static clock repository

❗ Configure GitHub Pages

Go the the Pages Settings and configure GitHub Pages to deploy the root of the main branch:

Configure GitHub Pages

Save the changes.

❗ What else?

You're done! It's as simple as that.

You should be able to access your deployed static website at https://johndoe.github.io/static-clock-website (replacing johndoe with your GitHub username).

💎 It may take a couple of minutes for the site to become available.

❗ Make a change to test the automated deployment

If you push a new commit to your repository (or make one on GitHub), you can see that the new version will be automatically deployed!

💎 It can take a couple of minutes for new commits to be deployed by GitHub Pages.

🏁 What have I done?

In this exercise, you have deployed a static website to GitHub Pages, a static site hosting service and a type of PaaS platform, using nothing but the web interface provided by GitHub. You did not have to do any of the following:

  • Hosting
  • Reverse proxying
  • TLS encryption
  • Automated deployments
  • Domain name

GitHub Pages is free for public repositories. Read their documentation for more information.