Skip to content

Commit

Permalink
Merge pull request #58 from foomo/blank
Browse files Browse the repository at this point in the history
Blank
  • Loading branch information
franklinkim authored Jan 31, 2025
2 parents 2f10383 + 5258b14 commit a51efb9
Show file tree
Hide file tree
Showing 10 changed files with 220 additions and 1 deletion.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ schema: PWD=$(pwd)
schema:
@echo "--- schema ---------------------------------------"
helm-schema -n -c charts/beam
helm-schema -n -c charts/blank
helm-schema -n -c charts/namespace
helm-schema -n -c charts/sesamy-gtm
helm-schema -n -c charts/sesamy-umami
Expand Down
23 changes: 23 additions & 0 deletions charts/blank/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
18 changes: 18 additions & 0 deletions charts/blank/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: v2
type: application
name: blank
description: Blank Resource Chart
icon: https://avatars.githubusercontent.com/u/889755?s=200&v=4
home: https://www.foomo.org
keywords:
- foomo
- blank
sources:
- https://github.com/foomo/helm-charts
annotations:
"artifacthub.io/links": |
- name: Chart Source
url: https://github.com/foomo/helm-charts/tree/main/charts/blank
version: 0.1.0
appVersion: 0.1.0
27 changes: 27 additions & 0 deletions charts/blank/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# blank

![Version: 0.1.0](https://img.shields.io/badge/Version-0.1.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.1.0](https://img.shields.io/badge/AppVersion-0.1.0-informational?style=flat-square)

Blank Resource Chart

**Homepage:** <https://www.foomo.org>

## Source Code

* <https://github.com/foomo/helm-charts>

## Values

### Overrides

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| fullnameOverride | string | `""` | Overrides the chart's computed fullname |
| nameOverride | string | `""` | Overrides the chart's name |
| namespaceOverride | string | `""` | The name of the Namespace to deploy |

### General

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| templates | object | `{}` | Custom templates to inject |
16 changes: 16 additions & 0 deletions charts/blank/README.md.gotmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{{ template "chart.header" . }}
{{ template "chart.deprecationWarning" . }}

{{ template "chart.badgesSection" . }}

{{ template "chart.description" . }}

{{ template "chart.homepageLine" . }}

{{ template "chart.maintainersSection" . }}

{{ template "chart.sourcesSection" . }}

{{ template "chart.requirementsSection" . }}

{{ template "chart.valuesSection" . }}
58 changes: 58 additions & 0 deletions charts/blank/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "blank.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
If release name contains chart name it will be used as a full name.
*/}}
{{- define "blank.fullname" -}}
{{- if .Values.fullnameOverride }}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- $name := default .Chart.Name .Values.nameOverride }}
{{- if contains $name .Release.Name }}
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
{{- end }}
{{- end }}
{{- end }}

{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "blank.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Common labels
*/}}
{{- define "blank.labels" -}}
helm.sh/chart: {{ include "blank.chart" . }}
{{ include "blank.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}

{{/*
Selector labels
*/}}
{{- define "blank.selectorLabels" -}}
app.kubernetes.io/name: {{ include "blank.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Create the name of the namespace
*/}}
{{- define "blank.namespace" -}}
{{- default .Release.Namespace .Values.namespaceOverride }}
{{- end }}
6 changes: 6 additions & 0 deletions charts/blank/templates/templates.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{{- $files := .Files }}
{{- range $filename, $template := .Values.templates }}
# Filename: {{ $filename }}
{{ tpl $template $ }}
---
{{- end }}
42 changes: 42 additions & 0 deletions charts/blank/values.schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"fullnameOverride": {
"default": "",
"description": "Overrides the chart's computed fullname",
"required": [],
"title": "fullnameOverride",
"type": "string"
},
"global": {
"description": "Global values are values that can be accessed from any chart or subchart by exactly the same name.",
"required": [],
"title": "global",
"type": "object"
},
"nameOverride": {
"default": "",
"description": "Overrides the chart's name",
"required": [],
"title": "nameOverride",
"type": "string"
},
"namespaceOverride": {
"default": "",
"description": "The name of the Namespace to deploy",
"required": [],
"title": "namespaceOverride",
"type": "string"
},
"templates": {
"additionalProperties": true,
"description": "Custom templates to inject",
"required": [],
"title": "templates",
"type": "object"
}
},
"required": [],
"type": "object"
}
28 changes: 28 additions & 0 deletions charts/blank/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# yaml-language-server: $schema=values.schema.json

# @schema
# type: string
# @schema
# -- Overrides the chart's name
# @section -- Overrides
nameOverride: ''
# @schema
# type: string
# @schema
# -- Overrides the chart's computed fullname
# @section -- Overrides
fullnameOverride: ''
# @schema
# type: string
# @schema
# -- The name of the Namespace to deploy
# @section -- Overrides
namespaceOverride: ''

# @schema
# type: object
# additionalProperties: true
# @schema
# -- Custom templates to inject
# @section -- General
templates: {}
2 changes: 1 addition & 1 deletion charts/namespace/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ sources:
annotations:
"artifacthub.io/links": |
- name: Chart Source
url: https://github.com/foomo/helm-charts
url: https://github.com/foomo/helm-charts/tree/main/charts/namespace
version: 0.2.4
appVersion: 0.2.4

0 comments on commit a51efb9

Please sign in to comment.