Skip to content

Commit 6cce980

Browse files
authored
Add docs website publishing (#39)
* Update pipeline * Add base to vitepress config * Update README
1 parent fe54359 commit 6cce980

File tree

4 files changed

+32
-18
lines changed

4 files changed

+32
-18
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
1-
# ---------------------------------------------------------
2-
# Title: Continuous Integration
3-
#
4-
# Uses:
1+
# title: Continuous Integration
2+
# uses:
53
# - https://github.com/helm/chart-testing-action
64
# - https://github.com/helm/kind-action
7-
# ---------------------------------------------------------
85

96
name: CI
107

.github/workflows/pkg.yml

Lines changed: 28 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,11 @@
1-
# ---------------------------------------------------------------------------------------
2-
# Title: Continuous Delivery (Packaging)
3-
#
4-
# Requirements:
1+
# title: Continuous Delivery (Packaging)
2+
# requirements:
53
# - Create manually "gh-pages" branch
64
# - Maintain pages files in "gh-pages" branch: index.tpl, placeholder.png
7-
#
8-
# Uses:
5+
# uses:
96
# - https://github.com/helm/chart-releaser-action
107
# - https://github.com/halkeye/helm-repo-html
11-
# ---------------------------------------------------------------------------------------
8+
# - https://github.com/actions/configure-pages
129

1310
name: PKG
1411

@@ -23,6 +20,10 @@ permissions:
2320
pages: write
2421
id-token: write
2522

23+
concurrency:
24+
group: pages
25+
cancel-in-progress: false
26+
2627
jobs:
2728
build:
2829
runs-on: ubuntu-latest
@@ -38,9 +39,14 @@ jobs:
3839
cache: npm
3940
- name: Install Node.js dependencies
4041
run: npm install
42+
# ref. https://vitepress.dev/guide/deploy#github-pages
4143
- name: Build with VitePress
4244
run: npm run docs:build
43-
# https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address
45+
- uses: actions/upload-artifact@v4
46+
with:
47+
name: docs
48+
path: docs/.vitepress/dist/
49+
# ref. https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address
4450
- name: Configure Git
4551
run: |
4652
git config user.name "$GITHUB_ACTOR"
@@ -61,6 +67,14 @@ jobs:
6167
uses: actions/checkout@v4
6268
with:
6369
ref: gh-pages
70+
- uses: actions/download-artifact@v4
71+
with:
72+
name: docs
73+
path: docs
74+
- name: DEBUG
75+
run: |
76+
ls -alrt .
77+
ls -alrt docs
6478
- name: Setup Go environment
6579
uses: actions/setup-go@v5
6680
- name: Generate index.html
@@ -76,16 +90,18 @@ jobs:
7690
destination: ./_site
7791
- name: Copy docs to website folder
7892
run: |
79-
mkdir -p _site/docs
80-
cp -r docs/.vitepress/dist/* _site/docs/
93+
id
94+
ls -alrt ./_site
95+
sudo mkdir -p ./_site/docs
96+
sudo cp -r docs/* ./_site/docs/
8197
- name: Upload artifact
8298
uses: actions/upload-pages-artifact@v3
8399
deploy:
100+
runs-on: ubuntu-latest
101+
needs: build
84102
environment:
85103
name: github-pages
86104
url: ${{ steps.deployment.outputs.page_url }}
87-
runs-on: ubuntu-latest
88-
needs: build
89105
steps:
90106
- name: Deploy to GitHub Pages
91107
id: deployment

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
This repository provides a list of community, vendor and home Helm charts to easily configure and run workloads in Kubernetes clusters.
77
Feel free to [contribute](CONTRIBUTING.md)!
88

9-
Latest chart versions are available from [devpro.github.io/helm-charts](https://devpro.github.io/helm-charts/).
9+
Get started with the [documentation](https://devpro.github.io/helm-charts/docs/).
1010

1111
## Usage
1212

docs/.vitepress/config.mts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { generateSidebar } from 'vitepress-sidebar'
55
export default defineConfig({
66
title: "Devpro Helm Chart Guide",
77
description: "A guide to make the best use of Helm charts to manage workload in Kubernetes clusters",
8+
base: '/helm-charts/docs/',
89
themeConfig: {
910
// https://vitepress.dev/reference/default-theme-config
1011
nav: [

0 commit comments

Comments
 (0)