Source for the main Harbor website
Go to file
Wang Yan aef1a978b4
Merge pull request #649 from wy65701436/release-2.13.0-update
add document for v2.13
2025-04-16 15:29:36 +08:00
.github Add auto-assignees for PRs 2023-02-13 15:30:15 +02:00
assets/sass feat: added style to add horizontal scrollbars on tables if are bigger (#587) 2024-11-19 10:02:33 +01:00
content Add blog for KubeCon London with videos (#631) 2025-02-07 16:46:58 +08:00
data Remove broken links from partners and users (#625) 2025-02-07 11:19:00 +08:00
docs document for v2.13 2025-04-16 14:58:08 +08:00
harbor@db1569ae20 document for v2.13 2025-04-16 14:58:08 +08:00
layouts To be compliant with GDPR, CCPA and other major regulations, we need to 2025-02-18 11:15:46 +08:00
static Remove broken links from partners and users (#625) 2025-02-07 11:19:00 +08:00
.backportrc.json add document for v2.13 2025-04-16 15:21:29 +08:00
.browerslistrc Add Edge support and IE-friendly JavaScript 2020-03-20 15:30:53 -07:00
.editorconfig Fix issue in rendered links 2020-01-15 11:34:18 -08:00
.gitignore Add OIDC Group Filter field (#382) 2022-12-02 11:49:49 +08:00
.gitmodules Change favicon 2020-02-03 14:37:32 -08:00
.htmltest.external.yml Enable external link checking 2020-02-25 07:56:35 -08:00
.htmltest.yml Add link checker and begin fixing errant links 2020-02-17 13:27:02 -08:00
.nvmrc update pacakges and ignore links in link checker 2020-09-22 09:41:16 -04:00
CODEOWNERS Add CODEOWNERS from sig-community and sig-docs (#317) 2022-04-05 16:22:06 +03:00
LICENSE Initial commit 2018-07-12 12:16:34 -04:00
Makefile Bind host to 0.0.0.0 (#376) 2022-11-01 14:52:28 +02:00
README.md Add license scan report and status (#370) 2024-10-02 14:28:09 +02:00
config.toml add document for v2.13 2025-04-16 15:21:29 +08:00
load-docs.sh Update load-docs.sh to use main instead of master branch 2022-01-18 15:59:01 -05:00
netlify.toml Add new documentation guidelines to README 2020-07-21 20:49:39 -04:00
package-lock.json Bump braces from 3.0.2 to 3.0.3 (#557) 2024-10-03 09:48:37 +03:00
package.json update pacakges and ignore links in link checker 2020-09-22 09:41:16 -04:00
postcss.config.js Add PostCSS to build pipeline 2020-03-19 17:39:08 -07:00
yarn.lock Bump braces from 3.0.2 to 3.0.3 (#557) 2024-10-03 09:48:37 +03:00

README.md

The Harbor website

FOSSA Status

This repo houses the assets used to build the Harbor website, available at https://goharbor.io.

Tools

The website is built and developed using the Hugo static site generator.

Instructions for installing Hugo can be found here. Use the version of Hugo specified by the HUGO_VERSION environment variable in the netlify.toml configuration file, and make sure to install the "extended" version of Hugo with support for Hugo Pipes.

backport is used to backport PRs into different release branches.

Website content

The content for the Harbor blog is in content/blog, while the content for the Harbor documentation is in the docs folder.

The latest (edge) version of the documentation lives in the docs folder on the main branch, and is always viewable on https://goharbor.io/docs/edge. Documentation for specific released versions lives in its own release branch, for example release-2.1.0.

Creating a PR

In general, all PRs should be made against the main branch to update the edge version of the docs. If you are making a change that also affects released versions, indicate which release branches to update in your PR so a website maintainer can backport your changes.

If you are making a change that is specific to a single released version of documentation, make a PR against that branch (release-X). For example, if you are fixing something specific to v2.1.0 you should make a PR against the release-2.1.0 branch only. If you are fixing something that impacts v2.1.0 docs and all future versions, you should make the PR against the main branch so the change can also be backported to the v2.1.0 docs.

A preview of your changes is viewable through the Netlify preview linked in the PR tests. Use this to verify that your changes look good before asking the maintainers for a review. When updating the edge version make sure you add /docs/edge/ to the preview URL to see your changes.

Creating release docs

When creating docs for a new release, please create a branch with the format release-X.Y.Z. When you want to make these docs available through the dropdown menu, put the following into the config.toml file, above all other versions (versions are linked based on order in the config file):

[[params.versions]]
harborversion = "X.Y.Z"
helmversion = "1.3"
branchname = "release-X.Y.Z"

As last step, update the _index.md file with the new version number and correct links.

After a release, update the backport tool configuration file, .backportrc.json, with the new release branch name.

CSS

The CSS for the site is built from Sass inputs in the assets/sass directory. There is also a small amount of JavaScript logic for the site in assets/js/app.js.

Publishing the website

The Harbor website is published automatically on the Netlify platform. Whenever changes are merged, the site is re-built and re-deployed, usually within about one minute.

Run the Harbor website locally

Step 1: Clone project

git clone https://github.com/goharbor/website.git
cd website

Step 2: Load documentation content

The Markdown content for the Harbor docs is drawn from the docs folder and the release-X branches. To pull that content into your local website repo:

make prepare

This copies the docs directory and the release-X branches into this repo's content folder, separated by versions, where it can be processed by Hugo.

Step 3: Install npm dependencies

npm i

Step 4: Run Hugo in server mode

make serve

This starts up the local Hugo server on http://localhost:1313. As you make changes, the site refreshes automatically in your browser.

To run the link checker for the Harbor website:

make check-internal-links

This command builds the site (including drafts and future content), downloads the htmltest link checker into your local directory, and runs the checker in accordance with the configuration specified in .htmltest.yml. Only internal links are checked and all errors are piped to stdout.

License

FOSSA Status