File tree Expand file tree Collapse file tree 2 files changed +21
-2
lines changed
Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change 66jobs :
77 publish-charts :
88 runs-on : ubuntu-latest
9+ if : github.repository == 'aws/eks-node-monitoring-agent'
910 steps :
10- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
11+ - name : " Checkout"
12+ uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
1113 with :
12- ref : ' main '
14+ fetch-depth : 0
1315 - name : " Setup Helm"
1416 uses : azure/setup-helm@b9e51907a09c216f16ebe8536097933489208112 # 4.3.0
1517 - name : " Publish Charts"
Original file line number Diff line number Diff line change @@ -7,7 +7,24 @@ VERSION=$(git describe --tags --always)
77STAGING_DIR=${1:- ${GIT_REPO_ROOT} }
88CHART_URL=${2:- https:// aws.github.io/ eks-node-monitoring-agent}
99
10+ git fetch --all
11+ git config user.email
[email protected] 12+ git config user.name eks-bot
13+
1014helm package ${GIT_REPO_ROOT} /charts/* --destination ${STAGING_DIR} --dependency-update
15+
16+ for bundle in ${STAGING_DIR} /* .tgz; do
17+ if git cat-file -e origin/gh-pages:${bundle} ; then
18+ echo " ⏩ Release already exists for ${bundle} "
19+ rm -f ${bundle}
20+ fi
21+ done
22+
23+ if ! ls ${STAGING_DIR} /* .tgz; then
24+ echo " ⏩ No changes to be staged"
25+ exit 0
26+ fi
27+
1128git checkout gh-pages
1229mv ${STAGING_DIR} /* .tgz .
1330helm repo index . --url ${CHART_URL}
You can’t perform that action at this time.
0 commit comments