This repository houses all of the assets used to build the etcd docs and website available at https://etcd.io.
To build and serve the site, you'll need these tools:
- Hugo, extended edition; match the version specified in netlify.toml
- Node, the latest LTS release. Like Netlify, we use nvm, the
Node Version Manager, to install and manage Node versions:
$ nvm install --lts $ nvm use --lts
Once you've installed the prerequisites, get local packages:
npm install
Once the setup has completed, you can locally serve the site:
npm run serve
You can also run the site locally using Docker:
make docker-serve
The site is published automatically by Netlify. Any time changes are pushed to the main branch, the site is built and deployed.
Any time you submit a pull request to this repository, Netlify will publish a preview build of the changes in that pull request. You can find a link to the preview build in the checks section of the pull request, under netlify/etcd/deploy-preview.
Follow these steps to add documentation for a newly released version of etcd, vX.Y:
-
Recursively copy content/docs/next into
content/docs/vX.Y
, wherevX.Y
is the newly released version of etcd. For example:cp -r content/docs/next content/docs/v3.5
-
In the
_index.md
file at the root of the new directory, update the frontmatter to reflect the new version:--- title: etcd version X.Y weight: 1000 cascade: version: vX.Y ---
-
Add the version to the
params.versions.all
array in the config.toml configuration file. -
If the version is meant to be the latest version of etcd, change the
params.versions.latest
parameter to the desired new version. -
Submit a pull request with the changes.
If you have an issue with updating the documentation, file an issue against this repo.