mirror of
https://github.com/stakater/Reloader.git
synced 2026-08-20 04:26:28 +00:00
added reloader-enterprise dependency
This commit is contained in:
@@ -54,7 +54,7 @@ jobs:
|
||||
- name: Get version for chart from helm repo
|
||||
id: chart_eval
|
||||
run: |
|
||||
current_chart_version=$(helm search repo stakater/reloader | tail -n 1 | awk '{print $2}')
|
||||
current_chart_version=$(helm search repo stakater/reloader-v2 | tail -n 1 | awk '{print $2}')
|
||||
echo "CURRENT_CHART_VERSION=$(echo ${current_chart_version})" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Get Updated Chart version from Chart.yaml
|
||||
@@ -63,7 +63,10 @@ jobs:
|
||||
with:
|
||||
cmd: yq e '.version' deployments/kubernetes/chart/reloader/Chart.yaml
|
||||
|
||||
# Skip the version-increase gate on first publish, when no reloader-v2
|
||||
# chart exists yet in the repo (CURRENT_CHART_VERSION is empty).
|
||||
- name: Check Version
|
||||
if: steps.chart_eval.outputs.CURRENT_CHART_VERSION != ''
|
||||
uses: aleoyakas/check-semver-increased-action@415c9c60054c2442c03478b6dd96a195deac6695 # v1
|
||||
id: check-version
|
||||
with:
|
||||
@@ -71,7 +74,7 @@ jobs:
|
||||
previous-version: ${{ steps.chart_eval.outputs.CURRENT_CHART_VERSION }}
|
||||
|
||||
- name: Fail if Helm Chart version isnt updated
|
||||
if: steps.check-version.outputs.is-version-increased != 'true'
|
||||
if: steps.chart_eval.outputs.CURRENT_CHART_VERSION != '' && steps.check-version.outputs.is-version-increased != 'true'
|
||||
run: |
|
||||
echo "Helm Chart Version wasnt updated"
|
||||
exit 1
|
||||
@@ -88,12 +91,15 @@ jobs:
|
||||
|
||||
- name: Publish Helm chart to ghcr.io
|
||||
run: |
|
||||
# Pull the enterprise subchart from private GHCR (uses the login above);
|
||||
# the vendored charts/*.tgz is gitignored, so it isn't present on the runner.
|
||||
helm dependency build ./deployments/kubernetes/chart/reloader
|
||||
helm package ./deployments/kubernetes/chart/reloader --destination ./packaged-chart
|
||||
helm push ./packaged-chart/*.tgz oci://ghcr.io/stakater/charts
|
||||
rm -rf ./packaged-chart
|
||||
|
||||
- name: Sign artifacts with Cosign
|
||||
run: cosign sign --yes ghcr.io/stakater/charts/reloader:${{ steps.new_chart_version.outputs.result }}
|
||||
run: cosign sign --yes ghcr.io/stakater/charts/reloader-v2:${{ steps.new_chart_version.outputs.result }}
|
||||
|
||||
- name: Publish Helm chart to gh-pages
|
||||
uses: stefanprodan/helm-gh-pages@0ad2bb377311d61ac04ad9eb6f252fb68e207260 # v1.7.0
|
||||
@@ -114,7 +120,7 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.PUBLISH_TOKEN }}
|
||||
WITH_V: false
|
||||
CUSTOM_TAG: chart-v${{ steps.new_chart_version.outputs.result }}
|
||||
CUSTOM_TAG: reloader-v2-chart-v${{ steps.new_chart_version.outputs.result }}
|
||||
|
||||
- name: Notify Slack
|
||||
uses: 8398a7/action-slack@77eaa4f1c608a7d68b38af4e3f739dcd8cba273e # v3
|
||||
|
||||
@@ -3,7 +3,7 @@ name: Release Helm chart
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "chart-v*"
|
||||
- "reloader-v2-chart-v*"
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
@@ -26,7 +26,7 @@ jobs:
|
||||
run: |
|
||||
gh release create "$tag" \
|
||||
--repo="$GITHUB_REPOSITORY" \
|
||||
--title="Helm chart ${tag#chart-}" \
|
||||
--title="Helm chart reloader-v2 ${tag#reloader-v2-chart-v}" \
|
||||
--generate-notes
|
||||
|
||||
- name: Notify Slack
|
||||
|
||||
@@ -147,7 +147,8 @@ jobs:
|
||||
run: |
|
||||
echo GHCR_IMAGE_REPOSITORY=${{env.REGISTRY}}/$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
|
||||
|
||||
# tag this image as latest as it will be used in plain manifests
|
||||
# v2 branch: publish a floating `v2` tag instead of `latest` so v2
|
||||
# releases never overwrite the v1 `latest` tag used by plain manifests.
|
||||
- name: Build and Push Docker Image to ghcr registry
|
||||
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6
|
||||
with:
|
||||
@@ -157,7 +158,7 @@ jobs:
|
||||
push: true
|
||||
platforms: linux/amd64,linux/arm,linux/arm64
|
||||
tags: |
|
||||
${{ env.GHCR_IMAGE_REPOSITORY }}:${{ steps.generate_tag.outputs.RELEASE_VERSION }},${{ env.GHCR_IMAGE_REPOSITORY }}:latest
|
||||
${{ env.GHCR_IMAGE_REPOSITORY }}:${{ steps.generate_tag.outputs.RELEASE_VERSION }},${{ env.GHCR_IMAGE_REPOSITORY }}:v2
|
||||
build-args: |
|
||||
VERSION=${{ steps.generate_tag.outputs.RELEASE_VERSION }}
|
||||
COMMIT=${{ github.sha }}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
apiVersion: v1
|
||||
name: reloader
|
||||
apiVersion: v2
|
||||
name: reloader-v2
|
||||
description: Reloader chart that runs on kubernetes
|
||||
version: 2.2.12
|
||||
appVersion: v1.4.17
|
||||
version: 2.0.0
|
||||
appVersion: v2.0.0
|
||||
keywords:
|
||||
- Reloader
|
||||
- kubernetes
|
||||
@@ -17,3 +17,9 @@ maintainers:
|
||||
email: rasheed@stakater.com
|
||||
- name: faizanahmad055
|
||||
email: faizan@stakater.com
|
||||
dependencies:
|
||||
- name: reloader-enterprise
|
||||
alias: enterprise
|
||||
version: 0.1.0
|
||||
repository: oci://ghcr.io/stakater/charts
|
||||
condition: enterprise.enabled
|
||||
|
||||
@@ -170,6 +170,55 @@ helm uninstall {{RELEASE_NAME}} -n {{NAMESPACE}}
|
||||
### Deprecation Notice
|
||||
- `serviceMonitor` will be removed in future releases in favor of `PodMonitor`
|
||||
|
||||
## Enterprise mode
|
||||
|
||||
Reloader Enterprise adds a console, gateway, and cache (dragonfly) alongside the
|
||||
operator. It ships as an optional subchart gated by `enterprise.enabled`.
|
||||
|
||||
Enabling it requires **four** changes, because the operator image is swapped manually:
|
||||
|
||||
1. Turn on the subchart and set the component hostnames:
|
||||
|
||||
```yaml
|
||||
enterprise:
|
||||
enabled: true
|
||||
global:
|
||||
consoleHost: reloader-enterprise-console.apps.example.com
|
||||
gatewayHost: reloader-enterprise-gateway.apps.example.com
|
||||
```
|
||||
|
||||
2. Swap the operator image to the enterprise image:
|
||||
|
||||
```yaml
|
||||
image:
|
||||
repository: ghcr.io/stakater/reloader-enterprise
|
||||
tag: v0.1.0
|
||||
```
|
||||
|
||||
3. Provide an image pull secret — the enterprise operator, console, and gateway
|
||||
images are in **private GHCR**:
|
||||
|
||||
```bash
|
||||
kubectl create secret docker-registry saap-dockerconfigjson \
|
||||
--docker-server=ghcr.io \
|
||||
--docker-username=<user> --docker-password=<token> \
|
||||
-n <release-namespace>
|
||||
```
|
||||
|
||||
```yaml
|
||||
global:
|
||||
imagePullSecrets:
|
||||
- name: saap-dockerconfigjson
|
||||
```
|
||||
|
||||
4. Deeper enterprise component settings pass through under `enterprise.console.*`,
|
||||
`enterprise.gateway.*`, and `enterprise.dragonfly.*` (see the reloader-enterprise
|
||||
chart values for the full list). Values you do not override fall back to the
|
||||
subchart defaults.
|
||||
|
||||
When `enterprise.enabled=false` (the default) none of the enterprise components are
|
||||
rendered and the operator uses the community image.
|
||||
|
||||
## Release Process
|
||||
|
||||
_Helm chart versioning_: The Reloader Helm chart is maintained in this repository. The Helm chart has its own semantic versioning. Helm charts and code releases are separate artifacts and separately versioned. Manifest making strategy relies on Kustomize. The Reloader Helm chart manages the two artifacts with these two fields:
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
suite: Enterprise image swap
|
||||
templates:
|
||||
- deployment.yaml
|
||||
tests:
|
||||
- it: uses the community image by default
|
||||
asserts:
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].image
|
||||
value: ghcr.io/stakater/reloader:v2.0.0
|
||||
- it: uses the enterprise image when the image block is overridden
|
||||
set:
|
||||
enterprise:
|
||||
enabled: true
|
||||
image:
|
||||
repository: ghcr.io/stakater/reloader-enterprise
|
||||
tag: v2.0.0
|
||||
asserts:
|
||||
- equal:
|
||||
path: spec.template.spec.containers[0].image
|
||||
value: ghcr.io/stakater/reloader-enterprise:v2.0.0
|
||||
@@ -10,6 +10,11 @@ global:
|
||||
#imagePullSecrets:
|
||||
# - my-pull-secret
|
||||
|
||||
## Required when enterprise.enabled=true (shared with the enterprise subchart)
|
||||
consoleHost: ""
|
||||
gatewayHost: ""
|
||||
gatewayScheme: https
|
||||
|
||||
kubernetes:
|
||||
host: https://kubernetes.default
|
||||
|
||||
@@ -19,10 +24,24 @@ fullnameOverride: ""
|
||||
image:
|
||||
name: stakater/reloader
|
||||
repository: ghcr.io/stakater/reloader
|
||||
tag: v1.4.19
|
||||
tag: v2.0.0
|
||||
# digest: sha256:1234567
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
# Reloader Enterprise components (console + gateway + dragonfly cache).
|
||||
# When enabled, ALSO set image.repository/image.tag to the enterprise operator
|
||||
# image and provide global.imagePullSecrets — see the chart README "Enterprise mode".
|
||||
enterprise:
|
||||
enabled: false
|
||||
console:
|
||||
enabled: true
|
||||
gateway:
|
||||
enabled: true
|
||||
dragonfly:
|
||||
enabled: true
|
||||
dragonfly:
|
||||
fullnameOverride: reloader-enterprise-dragonfly
|
||||
|
||||
reloader:
|
||||
autoReloadAll: false
|
||||
isArgoRollouts: false
|
||||
|
||||
Reference in New Issue
Block a user