Skip to content

Commit

Permalink
Merge pull request #35 from MarshallWace/helm-test
Browse files Browse the repository at this point in the history
add chart test and lint workflow
  • Loading branch information
mw-cying authored Jan 23, 2023
2 parents 7d67174 + 40adece commit b516c6f
Show file tree
Hide file tree
Showing 7 changed files with 60 additions and 60 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/lint-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Lint and Test Charts

on: pull_request

jobs:
lint-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Set up Helm
uses: azure/setup-helm@v3
with:
version: v3.10.0

- uses: actions/setup-python@v4
with:
python-version: '3.9'
check-latest: true

- name: Set up chart-testing
uses: helm/[email protected]

- name: Run chart-testing (list-changed)
id: list-changed
run: |
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }})
if [[ -n "$changed" ]]; then
echo "::set-output name=changed::true"
fi
- name: Run chart-testing (lint)
run: ct lint --target-branch ${{ github.event.repository.default_branch }} --validate-maintainers=false

- name: Create kind cluster
uses: helm/[email protected]
if: steps.list-changed.outputs.changed == 'true'

- name: Run chart-testing (install)
run: ct install
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -229,4 +229,7 @@ helm repo add gh_mwam https://marshallwace.github.io/cachenator/
helm repo update
helm search repo cachenator
helm pull gh_mwam/cachenator --version 0.1.0
```
```
If you are using custom S3 endpoint, in env vars, you will need to specific `AWS_REGION` and `AWS_CA_BUNDLE`.
You can pass in credentials using either (`AWS_SHARED_CREDENTIALS_FILE` and `AWS_PROFILE`)
or (`AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`)
2 changes: 1 addition & 1 deletion charts/cachenator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.1
version: 0.1.2
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
image:
registry: docker-ghcr-remote.abc.local
registry: ghcr.io
image: marshallwace/cachenator
tag: 0.19.1

Expand Down Expand Up @@ -45,4 +45,6 @@ volumes:
items:
- key: root-ca
path: ca.crt
configs: {}
configs:
root-ca: |
some cert here
2 changes: 1 addition & 1 deletion charts/cachenator/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ spec:
- "-read-only"
{{- end }}
{{- if .Values.metrics.enabled }}
- "metrics-port={{ .Values.metrics.metrics_port }}"
- "-metrics-port={{ .Values.metrics.metrics_port }}"
{{ else }}
- "-disable-http-metrics"
{{- end }}
Expand Down
21 changes: 0 additions & 21 deletions charts/cachenator/templates/vpa.yaml

This file was deleted.

41 changes: 7 additions & 34 deletions charts/cachenator/values.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
image:
registry: https://marshallwace.github.io/
image: cachenator
tag: 0.1.0
registry: ghcr.io
image: marshallwace/cachenator
tag: 0.19.1

# Configures S3 proxy related settings
s3:
Expand Down Expand Up @@ -140,8 +140,8 @@ lifecycle: {}
# # some script


#For additional side-containers:
#sidecars:
# For additional side-containers:
# sidecars:
# - name: sidecar_name
# image: docker-registry/image:tag
# resources:
Expand Down Expand Up @@ -185,37 +185,10 @@ resources: {}
# cpu: 200m
# memory: 1024Mi

verticalPodAutoscaler:
updateMode: "Off"
# Set custom updateMode per container (optional)
# containerPolicies:
# - containerName: my-sidecar
# mode: "Off"
# - containerName: other-sidecar
# mode: "Initial"

# https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler
# updateMode can be:
# "Off" - Only recommends resource requests and limits
# "Initial" - Applies recommendations only at pod creation
# "Auto" - Automatically applies recommendations throughout the pod lifetime
verticalPodAutoscaler:
updateMode: "Off"
# Set custom updateMode per container (optional)
# containerPolicies:
# - containerName: my-sidecar
# mode: "Off"
# - containerName: other-sidecar
# mode: "Initial"



##################
#### Defaults ####
##################

# Applies to ingresses only
generateTLSCertificate: true
# default for now, shouldn't have to change unless we deploy more issuers
certIssuerName: vault-issuer

Expand All @@ -236,6 +209,6 @@ podSecurityContext: {}
# hostnames:
# - "foo.local"

#imagePullPolicy: IfNotPresent
# imagePullPolicy: IfNotPresent

mutating_webhook_configuration: {}
mutating_webhook_configuration: {}

0 comments on commit b516c6f

Please sign in to comment.