File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -38,14 +38,26 @@ jobs:
3838 # Step 4: Package the Helm chart
3939 - name : Package Helm Chart
4040 run : |
41- helm package charts/spring-boot --destination build/pages/charts
41+ helm package charts/spring-boot --destination build/pages
4242
4343 # Step 5: Generate the Helm repository index
4444 - name : Generate Index
4545 env :
46- CHART_REPO_URL : https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}/charts
46+ CHART_REPO_URL : https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}
4747 run : |
48- helm repo index build/pages/charts --url $CHART_REPO_URL
48+ helm repo index build/pages --url $CHART_REPO_URL
49+
50+ - name : Add redirect
51+ env :
52+ REDIRECT_URL : https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}/index.yaml
53+ run : |
54+ cat <<EOF > build/pages
55+ <!DOCTYPE html>
56+ <meta charset="utf-8">
57+ <title>Redirecting to ${REDIRECT_URL}</title>
58+ <meta http-equiv="refresh" content="0; URL=${REDIRECT_URL}">
59+ <link rel="canonical" href="${REDIRECT_URL}">
60+ EOF
4961
5062 - name : Setup Pages
5163 uses : actions/configure-pages@v5
You can’t perform that action at this time.
0 commit comments