Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support exposing service via metallb #175

Merged

Conversation

stuggi
Copy link
Contributor

@stuggi stuggi commented Feb 1, 2023

  • renames NetworkAttachmentDefinitions to NetworkAttachments
  • introduce externalEndpoints Parameters to configure metallb service using the pre-created metallb IPAddressPool and L2Advertisement .

E.g. to expose the api on an internalapi network which

  • should be registered as the internal endpoint
  • its metallb ipaddresspool is configured in an osp-internalapi object
  • and request a specific loadbalancerIP which is shared with other services (list of IPs for multi stack ipv4/ipv6)
...
spec:
...
      externalEndpoints:
      - endpoint: internal
        loadbalancerIPs:
        - 172.17.0.202
        ipAddressPool: osp-internalapi
        sharedIP: true
  • removes registration of admin endpoint

Depends-On: openstack-k8s-operators/lib-common#160

@stuggi
Copy link
Contributor Author

stuggi commented Feb 1, 2023

# openstack endpoint list
+----------------------------------+-----------+--------------+--------------+---------+-----------+-----------------------------------------------------------------+
| ID                               | Region    | Service Name | Service Type | Enabled | Interface | URL                                                             |
+----------------------------------+-----------+--------------+--------------+---------+-----------+-----------------------------------------------------------------+
| 040fa92602564b2c9421bd6d375683d4 | regionOne | keystone     | identity     | True    | internal  | http://keystone-internal.openstack.svc:5000                     |
| 6947e88973714c20a42266eb49d41d8c | regionOne | keystone     | identity     | True    | public    | http://keystone-public-openstack.apps.ostest.test.metalkube.org |
+----------------------------------+-----------+--------------+--------------+---------+-----------+-----------------------------------------------------------------+

@stuggi stuggi requested a review from olliewalsh February 1, 2023 16:33
@gibizer
Copy link
Contributor

gibizer commented Feb 1, 2023

The code looks good to me but I have limited knowledge around metallb.

@stuggi stuggi force-pushed the metallb_service branch 5 times, most recently from 912ad41 to 187f9c5 Compare February 3, 2023 08:12
@stuggi
Copy link
Contributor Author

stuggi commented Feb 3, 2023

/hold

@stuggi stuggi marked this pull request as ready for review February 3, 2023 09:25
@openshift-ci openshift-ci bot requested a review from Sandeepyadav93 February 3, 2023 09:25
@stuggi stuggi removed the request for review from Sandeepyadav93 February 13, 2023 12:57
@stuggi stuggi force-pushed the metallb_service branch 3 times, most recently from 658a74f to 499435b Compare February 14, 2023 09:59
Comment on lines +574 to +577
if err != nil {
return ctrl.Result{}, fmt.Errorf("failed create network annotation from %s: %w",
instance.Spec.NetworkAttachments, err)
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if eventually we might want to surface this in the conditions, but I suppose it will be rare for that nad.CreateNetworksAnnotation(...) func to ever return an error.

Copy link
Contributor

@abays abays left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 from me

@stuggi
Copy link
Contributor Author

stuggi commented Feb 17, 2023

/unhold

Copy link
Contributor

@gibizer gibizer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me

@stuggi
Copy link
Contributor Author

stuggi commented Feb 17, 2023

/test keystone-operator-build-deploy

Copy link
Contributor

@olliewalsh olliewalsh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Feb 17, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: olliewalsh, stuggi

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants