Hosting Hugo Static Web
In this new entry, we will check how to publish our hugo site. First, we will do using github pages and then changing the domain name as custom one.
Steps:
- Change the baseUrl content in the conf.toml
- using a github repository: We need to consider also to change the path “/” in all elements.
- using custom domain
- Create a github repository
- Put it as a public
- Change branch to main
- Build static side with “hugo -D” command
- Push your public folder with git “push -u origin main” command
- If you want custom domain, create CNAME file with your domain content
- Change DNS in your dns provider
- For update repository, we only need to build again with “hugo -D” command and then update repository with git.