Skip to content

Commit

Permalink
Merge pull request #90 from jonstacks/fix-notes-txt
Browse files Browse the repository at this point in the history
🐛 Fix rending of NOTES.txt
  • Loading branch information
jonstacks authored Dec 28, 2022
2 parents aede3af + 75432bd commit 3cdd811
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
4 changes: 4 additions & 0 deletions helm/ingress-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 0.3.1
### Fixed
- Fixes rendering of `NOTES.txt` when installing via helm

## 0.3.0
### Changed

Expand Down
2 changes: 1 addition & 1 deletion helm/ingress-controller/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: ngrok-ingress-controller
description: A Kubernetes ingress controller built using ngrok.
version: 0.3.0
version: 0.3.1
appVersion: 0.2.0
keywords:
- ngrok
Expand Down
14 changes: 7 additions & 7 deletions helm/ingress-controller/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,12 @@ be automatically configured on the internet using ngrok.

{{- $found := false }}
{{- range $svcIndex, $service := (lookup "v1" "Service" "" "").items }}
{{- if not $found }}
{{- range $portMapIdx, $portMap := $service.spec.ports }}
{{- if eq $portMap.port 80 443 }}
{{- if ne $service.metadata.name "kubernetes" }}
{{- $randomStr := randAlphaNum 8 }}}}
{{- if eq $portMap.port 80 443 }}
{{- if ne $service.metadata.name "kubernetes" }}
{{- $found = true -}}
{{- $randomStr := randAlphaNum 8 }}

One example, taken from your cluster, is the Service:
{{ $service.metadata.name | quote }}
Expand Down Expand Up @@ -39,12 +41,10 @@ spec:
--------------------------------------------------------------------------------
Applying this manifest will make the service {{ $service.metadata.name | quote }}
available on the public internet at "https://{{ $service.metadata.name -}}-{{- $randomStr -}}.ngrok.io/".

{{- $found = true -}}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
{{- if eq $found true }}{{break}}{{end}}
{{- end}}
{{- end }}

Once done, view your edges in the Dashboard https://dashboard.ngrok.com/cloud-edge/edges
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3cdd811

Please sign in to comment.