Documentation
This site uses Docsy and was forked from the docsy-example
Prerequisites
- Install hugo
- Clone kustomize
git clone git@github.com:kubernetes-sigs/cli-experimental && cd site/
Development
The doc input files are in the site
directory. The site can be hosted locally using
hugo server
.
cd site/
npm install
npm install -g postcss-cli
npm install autoprefixer
npm audit fix
hugo server
...
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Making a PR with your changes
Once you’ve verified that your changes look good using the local Hugo server, compile the HTML to be committed.
-
Commit the changes to the
site/
folder. Do not commit anything from thepublishedSite/
folder -
Open a PR.
-
Once status checks run on your PR, look for the
deploy/netlify
status check, and click theDetails
link to verify your change on Netlify.
Publishing docs in forked repository
We use Netlify to publish changes in the site. You can also enable netlify on you’re forked repo by doing the following step.
- Log into Netlify using your Github Credentials.
- Click New Site from Git button in the Netlify Dashboard.
- The setup has 3 steps.
- Connect to Git Provider - Select Github here and authenticate your Github account if not done earlier.
- Pick a repository - Select the forked repository here.
- Build options, and deploy! - Here set Branch to deploy to the branch that has the latest changes also set Publish directory to
./docs
.
Once deployed, you’ll have a URL pointing to the newly deployed site.
Setting Custom Domain & DNS changes
Note
This is applicable only for the site adminisrators on the event of site migration.- Make sure you’re a part of Kubernetes Docs Netlify team.
- Under Site Settings you’ll find Domain Management, where in you can set the site’s custom domain.
- Ideally, it should match up with the wild card
*.k8s.io
- Once custom domains are set on Netlify, you can raise a PR in k8s.io github repository.
- You’ll have to add this snippet in
dns/zone-configs/k8s.io._0_base.yaml
file:
# <github repo url> (@maintainers)
<custom_name>:
type: CNAME
value: <current_netlify_url>.
Useful Links
- Subproject Site Requests: https://github.com/kubernetes/community/blob/master/github-management/subproject-site-requests.md.
- Issue template for site request: https://github.com/kubernetes/org/issues/new/choose, select Netlify site request.
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.