feat(ambassador): add support for provider specific annotations

This commit is contained in:
Frederic Mereu 2023-12-17 16:28:06 +01:00
parent f71a82212e
commit 6cec5dd7df
No known key found for this signature in database
GPG Key ID: 8CE4FC10C7F26E85

View File

@ -166,13 +166,10 @@ func (sc *ambassadorHostSource) Endpoints(ctx context.Context) ([]*endpoint.Endp
// endpointsFromHost extracts the endpoints from a Host object
func (sc *ambassadorHostSource) endpointsFromHost(ctx context.Context, host *ambassador.Host, targets endpoint.Targets) ([]*endpoint.Endpoint, error) {
var endpoints []*endpoint.Endpoint
providerSpecific := endpoint.ProviderSpecific{}
setIdentifier := ""
annotations := host.Annotations
resource := fmt.Sprintf("host/%s/%s", host.Namespace, host.Name)
annotations := host.Annotations
providerSpecific, setIdentifier := getProviderSpecificAnnotations(annotations)
ttl := getTTLFromAnnotations(annotations, resource)
if host.Spec != nil {