Add regcache chart and use it as an ace-installer subchart#1280
Merged
Conversation
Add a standalone regcache Helm chart (charts/regcache) that deploys a CNCF Distribution (registry:3) pull-through cache, and consume it from ace-installer as a subchart (file://../regcache, condition regcache.enabled, default true). It proxies the upstream registry (ghcr.io by default) so ghcr.io/appscode-charts images are served from within the cluster. Cache image is ghcr.io/appscode-images/registry:3.1.1. The regcache chart is global-aware (modeled on charts/billing): it resolves its image registry from registryFQDN, OpenShift via Capabilities, and the PVC storage class from persistence.storageClass, else infra.storageClass.name, else the parent's global.infra.storageClass.name, else the cluster default. Its helpers are prefixed (regcache.*) to avoid Helm's global template-name collisions with the parent chart. ace-installer keeps an appscode-wizards-oci HelmRepository used by the platform UI deploy wizards. When regcache is enabled, its URL is rewritten to the in-cluster proxy Service so wizard chart pulls are served from the cache; the proxy serves plain HTTP, so the repository is marked insecure. The regcache.serviceAddress helper mirrors the subchart's fullname so the rewritten URL always matches the Service name. charts/ace-installer-certified and ace-installer-certified-crds are regenerated from charts/ace-installer via chart-packer and depend on ../regcache. update-chart-dependencies.sh now builds the ace-installer dependencies, and the bundled charts/ dirs are gitignored while Chart.lock is tracked. Signed-off-by: Tamal Saha <tamal@appscode.com>
Signed-off-by: Arnob kumar saha <arnob@appscode.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a standalone
charts/regcacheHelm chart — an in-cluster pull-through Docker registry cache (CNCF Distributionregistry:3) — and consumes it from ace-installer as a subchart (default enabled). It proxies the upstream registry (ghcr.ioby default) soghcr.io/appscode-chartsimages are served from within the cluster. A newappscode-wizards-ociHelmRepository routes through the cache when enabled.charts/regcache(new, standalone)charts/billing. Image:ghcr.io/appscode-images/registry:3.1.1(registryFQDN+image.registry).regcache.*) to avoid Helm's global template-name collisions with the parent.persistence.storageClass→infra.storageClass.name→ parentglobal.infra.storageClass.name→ cluster default (the billing$infraidiom).regcache.ttl(default72h) bounds disk usage; the cache purges entries older than the TTL and has no capacity-based eviction.ace-installer wiring
Chart.yamldependencyfile://../regcachewithcondition: regcache.enabled(defaulttrue);templates/regcache/removed.appscode-wizards-ociis rewritten to the in-cluster proxy Service (oci://<release>-regcache.<ns>.svc:5000/appscode-charts,insecure: true) when enabled, via the sharedace-installer.applyRegcachehelper. Theregcache.serviceAddresshelper mirrors the subchart's fullname so the URL always matches the Service name (verified across release names).API & plumbing
Regcache/RegcacheSpec(apis/installer/v1alpha1/regcache_types.go), registered;AceInstallerSpec.Regcachenow referencesRegcacheSpec.make codegenfor deepcopy.charts/ace-installer-certifiedand-certified-crdsregenerated viachart-packer(they depend on../regcache).update-chart-dependencies.shbuilds the ace-installer dependencies; bundledcharts/dirs are gitignored whileChart.lockis tracked.Generated artifacts
CRDs,
values.openapiv3_schema.yaml, and per-chartREADME.mdregenerated.catalog/imagelist.yamlcarriesghcr.io/appscode-images/registry:3.1.1(now also discoverable since regcache renders by default).