Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
k8s-ingress
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
uplex-varnish
k8s-ingress
Commits
2165e1e5
Commit
2165e1e5
authored
Jun 03, 2020
by
Geoff Simmons
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bugfix: check the ingress.class annotation on delete Ingress events.
parent
5e926688
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
8 deletions
+13
-8
ingress.go
pkg/controller/ingress.go
+13
-8
No files found.
pkg/controller/ingress.go
View file @
2165e1e5
...
...
@@ -1073,13 +1073,8 @@ func (worker *NamespaceWorker) isVarnishIngress(ing *extensions.Ingress) bool {
return
exists
&&
class
==
worker
.
ingClass
}
func
(
worker
*
NamespaceWorker
)
syncIng
(
key
string
)
error
{
nsKey
:=
worker
.
namespace
+
"/"
+
key
worker
.
log
.
Info
(
"Syncing Ingress:"
,
nsKey
)
ing
,
err
:=
worker
.
ing
.
Get
(
key
)
if
err
!=
nil
{
return
err
}
func
(
worker
*
NamespaceWorker
)
chkAddOrUpdateIng
(
ing
*
extensions
.
Ingress
)
error
{
if
!
worker
.
isVarnishIngress
(
ing
)
{
worker
.
log
.
Infof
(
"Ignoring Ingress %s/%s, Annotation '%v' "
+
...
...
@@ -1092,6 +1087,16 @@ func (worker *NamespaceWorker) syncIng(key string) error {
return
worker
.
addOrUpdateIng
(
ing
)
}
func
(
worker
*
NamespaceWorker
)
syncIng
(
key
string
)
error
{
nsKey
:=
worker
.
namespace
+
"/"
+
key
worker
.
log
.
Info
(
"Syncing Ingress:"
,
nsKey
)
ing
,
err
:=
worker
.
ing
.
Get
(
key
)
if
err
!=
nil
{
return
err
}
return
worker
.
chkAddOrUpdateIng
(
ing
)
}
func
(
worker
*
NamespaceWorker
)
addIng
(
key
string
)
error
{
return
worker
.
syncIng
(
key
)
}
...
...
@@ -1106,5 +1111,5 @@ func (worker *NamespaceWorker) deleteIng(obj interface{}) error {
worker
.
log
.
Warnf
(
"Delete Ingress: not found: %v"
,
obj
)
return
nil
}
return
worker
.
a
ddOrUpdateIng
(
ing
)
return
worker
.
chkA
ddOrUpdateIng
(
ing
)
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment