Skip to content

Commit 81abfcd

Browse files
committed
Merge branch 'master' of github.com:travisghansen/kubernetes-pfsense-controller
2 parents 8f3a76b + 42e1a40 commit 81abfcd

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

examples/declarative-example.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,11 @@ data:
111111
definition:
112112
name: some-frontend-name
113113
type: http
114-
forwardfor: yes
114+
forwardfor: "yes"
115115
status: active
116116
backend_serverpool: some-backend-name
117117
a_extaddr:
118118
item:
119119
- extaddr: wan_ipv4
120120
extaddr_port: 443
121-
extaddr_ssl: yes
121+
extaddr_ssl: "yes"

src/KubernetesPfSenseController/Plugin/HAProxyIngressProxy.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ public function doAction()
230230

231231
foreach ($item['spec']['rules'] as $ruleKey => $rule) {
232232
$aclName = $frontend['name'].'-rule-'.$ruleKey;
233-
$host = $rule['host'];
233+
$host = $rule['host'] ?? '';
234234
//$host = "*.${host}"; // for testing purposes only
235235
//$host = ""; // for testing purposes only
236236
if (!$this->shouldCreateRule($rule)) {
@@ -425,7 +425,7 @@ public function doAction()
425425
*/
426426
private function shouldCreateRule($rule)
427427
{
428-
$hostName = $rule['host'];
428+
$hostName = $rule['host'] ?? '';
429429
$pluginConfig = $this->getConfig();
430430
if (!empty($pluginConfig['allowedHostRegex'])) {
431431
$allowed = @preg_match($pluginConfig['allowedHostRegex'], $hostName);

0 commit comments

Comments
 (0)