Move pages to use the new repository design

This commit is contained in:
Alexander Olofsson 2021-09-23 10:29:08 +02:00
parent 6727fdcb93
commit 69a0617ab2
No known key found for this signature in database
GPG key ID: D439C9470CB04C73

View file

@ -11,27 +11,7 @@ lint:charts:
script: script:
- helm lint charts/* - helm lint charts/*
# pages: pages:
# image:
# name: codenest/helm
# entrypoint: ["/bin/sh", "-c"]
# stage: deploy
# before_script:
# - grep 'repository:' charts/*/Chart.yaml | awk '{ print $3 }' | uniq | xargs -rn1 sh -c 'helm repo add $(basename $0) $0'
# - helm repo update
# - ls -d1 charts/* | xargs -rn1 helm dependency build --skip-refresh
# script:
# - mkdir -p public
# - "echo \"User-Agent: *\nDisallow: /\" > ./public/robots.txt"
# - (cd public; helm package ../charts/*)
# - helm repo index public --url ${CI_PAGES_URL}
# artifacts:
# paths:
# - public
# only:
# - master@ananace/charts
push:
image: image:
name: codenest/helm name: codenest/helm
entrypoint: ["/bin/sh", "-c"] entrypoint: ["/bin/sh", "-c"]
@ -48,6 +28,7 @@ push:
curl --request POST --user gitlab-ci-token:$CI_JOB_TOKEN --form "chart=@$0" "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/api/${CHANNEL}/charts" curl --request POST --user gitlab-ci-token:$CI_JOB_TOKEN --form "chart=@$0" "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/api/${CHANNEL}/charts"
' '
- mkdir -p public - mkdir -p public
- "echo \"User-Agent: *\nDisallow: /\" > ./public/robots.txt"
- curl --user gitlab-ci-token:$CI_JOB_TOKEN "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/${CHANNEL}/index.yaml" -o public/index.yaml - curl --user gitlab-ci-token:$CI_JOB_TOKEN "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/${CHANNEL}/index.yaml" -o public/index.yaml
- sed -e "s|- charts/|- ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/${CHANNEL}/charts/|" -i public/index.yaml - sed -e "s|- charts/|- ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/helm/${CHANNEL}/charts/|" -i public/index.yaml
artifacts: artifacts: