Skip to content

Commit

Permalink
Merge pull request #22 from oliverbaehler/master
Browse files Browse the repository at this point in the history
[manifests]: Fixed Cronjob Bugs
  • Loading branch information
oliverbaehler authored Jan 18, 2021
2 parents 4c0f442 + 8fe9c92 commit da9c630
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 31 deletions.
22 changes: 8 additions & 14 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,24 +167,18 @@ annotations:

### Changelog

Changes on a chart must be documented in a chart specific changelog. For every new release the entire ```artifacthub.io/changes``` needs to be rewritten. Please use the following template:
Changes on a chart must be documented in a chart specific changelog. For every new release the entire artifacthub.io/changes needs to be rewritten. Each change requires a new bullet point following the pattern **[{type}]**: {description}. Please use the following template:


```
artifacthub.io/changes: |
**Added:**
* Added something within this chart
**Changed:**
* Changed Something within this chart
* Changed Something else within this chart
**Deprecated:**
* None
**Removed:**
* None
**Fixed:**
* Some Bug was fixed
**Security:**
* None
* **[Added]**: Something New was added
* **[Changed]**: Changed Something within this chart
* **[Changed]**: Changed Something else within this chart
* **[Deprecated]**: Something deprecated
* **[Removed]**: Something was removed
* **[Fixed]**: Something was fixed
* **[Security]**: Some Security Patch was included
```

# Workflows
Expand Down
16 changes: 3 additions & 13 deletions charts/manifests/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: manifests
description: "Bedag's Manifest chart. Library full of basic kubernetes manifests."
type: library
version: 0.4.3
version: 0.4.4
icon: "https://www.bedag.ch/wGlobal/wGlobal/layout/images/logo.svg"
keywords:
- Bedag
Expand All @@ -21,15 +21,5 @@ annotations:
artifacthub.io/containsSecurityUpdates: "false"
artifacthub.io/prerelease: "true"
artifacthub.io/changes: |
**Added:**
* None
**Changed:**
* Dependency `library` latest version
**Deprecated:**
* None
**Removed:**
* None
**Fixed:**
* [manifest/horizontalPodAutoscaler]: Metrics must be set for manifest to be returned
**Security:**
* None
* **[Fixed]**: Cronjob render correct manifest structure
* **[Fixed]**: Cronjob use Default API `batch/v1beta1`
2 changes: 1 addition & 1 deletion charts/manifests/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Manifests Library

![Version: 0.4.3](https://img.shields.io/badge/Version-0.4.3-informational?style=flat-square) ![Type: library](https://img.shields.io/badge/Type-library-informational?style=flat-square)
![Version: 0.4.4](https://img.shields.io/badge/Version-0.4.4-informational?style=flat-square) ![Type: library](https://img.shields.io/badge/Type-library-informational?style=flat-square)

This library's purpose is to have more flexibility as chart author but at the same time have kubernetes manifests managed in a central library. This way you can avoid big surprises when Kubernetes has breaking changes in any of their APIs. Currently we support a base set of resources. Resources may be added as soon as we see or get a request that there's a need for it. This chart is still under development and testing, since it's rather complex. Feel free to use it. Our goal is to get it as reliable as possible.

Expand Down
5 changes: 2 additions & 3 deletions charts/manifests/templates/manifests/_cronjob.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ kind: CronJob
{{- if $cronjob.apiVersion }}
apiVersion: {{ $cronjob.apiVersion }}
{{- else }}
apiVersion: batch/v1
apiVersion: batch/v1beta1
{{- end }}
metadata:
name: {{ include "bedag-lib.utils.common.fullname" . }}
Expand All @@ -46,8 +46,7 @@ spec:
startingDeadlineSeconds: {{ $cronjob.startingDeadlineSeconds }}
successfulJobsHistoryLimit: {{ $cronjob.successfulJobsHistoryLimit }}
suspend: {{ $cronjob.suspend }}
jobTemplate:
spec: {{- include "bedag-lib.template.job" (set . "job" $cronjob) | nindent 6 }}
jobTemplate: {{- include "bedag-lib.template.job" (set . "job" $cronjob) | nindent 4 }}
{{- end }}
{{- end }}
{{- end -}}

0 comments on commit da9c630

Please sign in to comment.