Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.

Commit

Permalink
chore: Bump edgelb version
Browse files Browse the repository at this point in the history
Signed-off-by: Simão Reis <[email protected]>
  • Loading branch information
Simão Reis authored and sreis committed Jul 3, 2019
1 parent 02b644d commit 8630870
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 27 deletions.
2 changes: 1 addition & 1 deletion docs/usage/11-provisioning-tcp-cloud-loadbalancers.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ To configure an AWS NLB, the value of the `.cloudProviderConfiguration` field mu
----
{
"aws": {
"elb": [{
"elbs": [{
"type": "NLB",
"name": "<name>",
"internal": <internal>,
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ require (
github.com/imdario/mergo v0.3.6 // indirect
github.com/json-iterator/go v1.1.5 // indirect
github.com/kr/pretty v0.1.0 // indirect
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190618110118-50a400af8d6f
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190628160932-d3547ca23ba9
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.1 // indirect
github.com/mongodb/mongo-go-driver v0.1.0
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190524045551-0e0d955a0325 h1:gqlVF
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190524045551-0e0d955a0325/go.mod h1:+p1l5IpJ27w9tnm4MY1yOLHCtu2sh6EoLUPTsGEYrjo=
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190618110118-50a400af8d6f h1:JM2honGf/OS+14RXRPGc2uOHSjjJVuzouv3UnVLHL4o=
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190618110118-50a400af8d6f/go.mod h1:+p1l5IpJ27w9tnm4MY1yOLHCtu2sh6EoLUPTsGEYrjo=
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190628160932-d3547ca23ba9 h1:Pkf3sS2A6RC+JIC5j1HtiCvaHzE8OWeZ8zE8uBxJ2EU=
github.com/mesosphere/dcos-edge-lb v1.3.2-0.20190628160932-d3547ca23ba9/go.mod h1:+p1l5IpJ27w9tnm4MY1yOLHCtu2sh6EoLUPTsGEYrjo=
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
github.com/mitchellh/mapstructure v1.1.2 h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE=
Expand Down
2 changes: 1 addition & 1 deletion make/edgelb.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ EDGELB_PACKAGE_NAME := edgelb
EDGELB_SERVICE_ACCOUNT_NAME := edgelb-principal

# EDGELB_PACKAGE_VERSION sets the required package version
EDGELB_PACKAGE_VERSION := v1.3.1-235-g50a400a
EDGELB_PACKAGE_VERSION := v1.3.1-269-g316af7d

.PHONY: edgelb.package.install
edgelb.package.install: dcos.setup-security.edgelb
Expand Down
48 changes: 25 additions & 23 deletions pkg/translator/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,29 +34,31 @@ func computeLoadBalancerStatus(manager manager.EdgeLBManager, poolName string, o
publicIPs = make(map[string]bool)
)
// Add all reported DNS names to the set of DNS names.
for _, elb := range m.Elb {
if elb.DNS != "" {
for _, listener := range elb.Listeners {
// Check whether the target frontend belongs to the Service/Ingress resource being processed.
if listener.LinkFrontend == nil {
continue
}
var (
isOwnedByObj bool
)
switch t := obj.(type) {
case *corev1.Service:
m, err := computeServiceOwnedEdgeLBObjectMetadata(*listener.LinkFrontend)
isOwnedByObj = err == nil && m.IsOwnedBy(t)
case *extsv1beta1.Ingress:
m, err := computeIngressOwnedEdgeLBObjectMetadata(*listener.LinkFrontend)
isOwnedByObj = err == nil && m.IsOwnedBy(t)
default:
return nil
}
// If the target frontend belongs to the Service/Ingress resource being processed, we add the DNS name of the ELB being processed.
if isOwnedByObj {
dnsNames[strings.ToLower(elb.DNS)] = true
if m.Aws != nil {
for _, elb := range m.Aws.Elbs {
if elb.DNS != "" {
for _, listener := range elb.Listeners {
// Check whether the target frontend belongs to the Service/Ingress resource being processed.
if listener.LinkFrontend == nil {
continue
}
var (
isOwnedByObj bool
)
switch t := obj.(type) {
case *corev1.Service:
m, err := computeServiceOwnedEdgeLBObjectMetadata(*listener.LinkFrontend)
isOwnedByObj = err == nil && m.IsOwnedBy(t)
case *extsv1beta1.Ingress:
m, err := computeIngressOwnedEdgeLBObjectMetadata(*listener.LinkFrontend)
isOwnedByObj = err == nil && m.IsOwnedBy(t)
default:
return nil
}
// If the target frontend belongs to the Service/Ingress resource being processed, we add the DNS name of the ELB being processed.
if isOwnedByObj {
dnsNames[strings.ToLower(elb.DNS)] = true
}
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/service_cloud_loadbalancer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ var _ = Describe("Service", func() {
// Create the desired cloud-provider configuration.
redisCfgBytes, _ := json.Marshal(&models.V2CloudProvider{
Aws: &models.V2CloudProviderAws{
Elb: []*models.V2CloudProviderAwsElb{
Elbs: []*models.V2CloudProviderAwsElb{
{
Internal: pointers.NewBool(false),
Listeners: []*models.V2CloudProviderAwsElbListener{
Expand Down

0 comments on commit 8630870

Please sign in to comment.