-
-
Notifications
You must be signed in to change notification settings - Fork 376
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add --ingress-class flag to openfaas-ingress
Allows users of traefik or other ingress controllers to set the value they need through a flag. Documented via flag and unit test updated. Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
- Loading branch information
Showing
2 changed files
with
19 additions
and
10 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
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 |
---|---|---|
|
@@ -7,8 +7,8 @@ import ( | |
"testing" | ||
) | ||
|
||
func Test_build_yaml_returns_correct_substitutions(t *testing.T) { | ||
templBytes, _ := buildYaml("openfaas.subdomain.example.com", "[email protected]") | ||
func Test_buildYAML_SubsitutesDomainEmailAndIngress(t *testing.T) { | ||
templBytes, _ := buildYAML("openfaas.subdomain.example.com", "[email protected]", "traefik") | ||
|
||
got := string(templBytes) | ||
if want != got { | ||
|
@@ -24,7 +24,7 @@ metadata: | |
namespace: openfaas | ||
annotations: | ||
cert-manager.io/cluster-issuer: letsencrypt-prod | ||
kubernetes.io/ingress.class: nginx | ||
kubernetes.io/ingress.class: traefik | ||
spec: | ||
rules: | ||
- host: openfaas.subdomain.example.com | ||
|
@@ -52,7 +52,7 @@ spec: | |
solvers: | ||
- http01: | ||
ingress: | ||
class: nginx` | ||
class: traefik` | ||
|
||
func Test_writeTempFile_writes_to_tmp(t *testing.T) { | ||
var want = "some input string" | ||
|