-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
dbea743
commit bf35123
Showing
3 changed files
with
38 additions
and
19 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
lint: | ||
@find ./charts/* -type d -maxdepth 0 | xargs -I{} bash -c "helm lint {}" | ||
|
||
template: | ||
# helm template ./charts/$(chart) | ||
helm install chart --dry-run ./charts/$(chart) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
apiVersion: v2 | ||
name: ledger | ||
description: A ledger for your CD pipeline | ||
version: 0.1.6 | ||
version: 0.1.7 | ||
appVersion: 0.1.5 | ||
sources: | ||
- https://github.com/stenic/helm-charts/tree/master/charts/ledger |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,34 @@ | ||
1. Get the application URL by running these commands: | ||
{{- if .Values.ingress.enabled }} | ||
{{- range $host := .Values.ingress.hosts }} | ||
{{- range .paths }} | ||
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ . }} | ||
{{- end }} | ||
{{- end }} | ||
{{- else if contains "NodePort" .Values.service.type }} | ||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "ledger.fullname" . }}) | ||
1. Get your 'admin' user password by running: | ||
printf $(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "ledger.fullname" . }} -o jsonpath="{.data.ledger-admin-password}" | base64 --decode);echo | ||
|
||
{{ if .Values.ingress.enabled }} | ||
2. Visit Ledger on: | ||
{{- range .Values.ingress.hosts }} | ||
- http://{{ .host }}/ | ||
{{- end -}} | ||
|
||
{{ else }} | ||
2. Get the Ledger URL to visit by running these commands in the same shell: | ||
{{- if contains "NodePort" .Values.service.type }} | ||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "ledger.fullname" . }}) | ||
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") | ||
echo http://$NODE_IP:$NODE_PORT | ||
echo http://$NODE_IP:$NODE_PORT/login | ||
{{- else if contains "LoadBalancer" .Values.service.type }} | ||
NOTE: It may take a few minutes for the LoadBalancer IP to be available. | ||
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "ledger.fullname" . }}' | ||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "ledger.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") | ||
echo http://$SERVICE_IP:{{ .Values.service.port }} | ||
{{- else if contains "ClusterIP" .Values.service.type }} | ||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "ledger.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") | ||
echo "Visit http://127.0.0.1:8080 to use your application" | ||
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:80 | ||
NOTE: It may take a few minutes for the LoadBalancer IP to be available. | ||
You can watch the status of by running 'kubectl get svc --namespace {{ .Release.Namespace }} -w {{ template "ledger.fullname" . }}' | ||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "ledger.fullname" . }} --template "{{ "{{ range (index .status.loadBalancer.ingress 0) }}{{ . }}{{ end }}" }}") | ||
echo http://$SERVICE_IP:{{ .Values.service.port }}/login | ||
{{- else if contains "ClusterIP" .Values.service.type }} | ||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") | ||
echo http://127.0.0.1:8080 | ||
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:8080 | ||
{{ end }} | ||
{{- end }} | ||
|
||
{{- if .Values.persistence.enabled }} | ||
{{- else }} | ||
################################################################################# | ||
###### WARNING: Persistence is disabled!!! You will lose your data when ##### | ||
###### the Ledger pod is terminated. ##### | ||
################################################################################# | ||
{{- end }} |