-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Nicolas Lamirault <nicolas.lamirault@gmail.com>
- Loading branch information
1 parent
03795ac
commit 2ee2984
Showing
4 changed files
with
111 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
apiVersion: v2 | ||
description: Gateway API CRDs | ||
name: gateway-api-crds | ||
version: 0.1.0 | ||
appVersion: 1.0.0 | ||
home: https:/https://gateway-api.sigs.k8s.io | ||
icon: https://avatars.githubusercontent.com/u/36015203?s=400&v=4 | ||
sources: | ||
- https://github.com/kubernetes-sigs/gateway-api | ||
keywords: | ||
- kubernetes | ||
- gateway-api | ||
- crds | ||
|
||
dependencies: | ||
- name: crds | ||
version: "0.0.0" | ||
|
||
maintainers: | ||
- name: nlamirault | ||
email: nicolas.lamirault@gmail.com | ||
url: https://github.com/nlamirault | ||
|
||
# https://artifacthub.io/docs/topics/repositories/ | ||
annotations: | ||
artifacthub.io/license: Apache-2.0 | ||
artifacthub.io/links: | | ||
- name: Kubernetes Gateway API | ||
url: https:/https://gateway-api.sigs.k8s.io | ||
- name: Chart Source | ||
url: https://github.com/portefaix/portefaix-hub | ||
artifacthub.io/maintainers: | | ||
- name: nlamirault | ||
email: nicolas.lamirault@gmail.com | ||
artifacthub.io/signKey: | | ||
fingerprint: C39918B3EBDE35C23B8D0B8E5F99269A6FCA437C | ||
url: https://keybase.io/nlamirault/pgp_keys.asc | ||
artifacthub.io/changes: | | ||
- kind: added | ||
description: Init chart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# gateway-api-crds | ||
|
||
![Version: 0.1.0](https://img.shields.io/badge/Version-0.1.0-informational?style=flat-square) ![AppVersion: 1.0.0](https://img.shields.io/badge/AppVersion-1.0.0-informational?style=flat-square) | ||
|
||
This chart brings Custom Resource Definitions (CRD) used by [Kubernetes Gateway API](https://github.com/kubernetes-sigs/gateway-api). | ||
|
||
## Maintainers | ||
|
||
| Name | Email | Url | | ||
| ---- | ------ | --- | | ||
| nlamirault | <nicolas.lamirault@gmail.com> | <https://github.com/nlamirault> | | ||
|
||
## Source Code | ||
|
||
* <https://github.com/kubernetes-sigs/gateway-api> | ||
|
||
## Requirements | ||
|
||
| Repository | Name | Version | | ||
|------------|------|---------| | ||
| | crds | 0.0.0 | | ||
|
||
## Values | ||
|
||
| Key | Type | Default | Description | | ||
|-----|------|---------|-------------| | ||
| crds.annotations | object | `{}` | | | ||
|
||
---------------------------------------------- | ||
Autogenerated from chart metadata using [helm-docs v1.11.3](https://github.com/norwoodj/helm-docs/releases/v1.11.3) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/bin/bash | ||
|
||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) | ||
|
||
FILES=( | ||
"gateway.networking.k8s.io_gatewayclasses.yaml" | ||
"gateway.networking.k8s.io_gateways.yaml" | ||
"gateway.networking.k8s.io_httproutes.yaml" | ||
gateway.networking.k8s.io_referencegrants.yaml | ||
) | ||
|
||
VERSION=$(grep appVersion ${SCRIPT_DIR}/../Chart.yaml | awk -F" " '{ print $2 }') | ||
echo "Gateway API: ${VERSION}" | ||
|
||
if [[ "$OSTYPE" == "linux-gnu"* ]]; then | ||
SED="sed" | ||
elif [[ "$OSTYPE" == "darwin"* ]]; then | ||
SED="gsed" | ||
fi | ||
|
||
for file in "${FILES[@]}"; do | ||
echo "CRD: ${file}" | ||
URL="https://raw.githubusercontent.com/kubernetes-sigs/gateway-api/v${VERSION}/config/crd/standard/${file}" | ||
if ! curl --silent --retry-all-errors --fail --location "${URL}" > "${SCRIPT_DIR}/../charts/crds/templates/${file}"; then | ||
echo -e "Failed to download ${URL}" | ||
exit 1 | ||
fi | ||
|
||
# Update or insert annotations block | ||
if yq -e '.metadata.annotations' "${SCRIPT_DIR}/../charts/crds/templates/${file}" >/dev/null; then | ||
${SED} -i '/^ annotations:$/a {{- with .Values.annotations }}\n{{- toYaml . | nindent 4 }}\n{{- end }}' "${SCRIPT_DIR}/../charts/crds/templates/${file}" | ||
else | ||
${SED} -i '/^metadata:$/a {{- with .Values.annotations }}\n annotations:\n{{- toYaml . | nindent 4 }}\n{{- end }}' "${SCRIPT_DIR}/../charts/crds/templates/${file}" | ||
fi | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
## Annotations for CRDs | ||
## | ||
crds: | ||
annotations: {} |