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

fix route53 wildcard handling #1370

Merged

Conversation

nabuskey
Copy link
Contributor

Signed-off-by: Manabu Mccloskey manabu.mccloskey@gmail.com

Description of your changes

Route53 does not return the * character if it sees it as a wildcard. e.g. For a record *.crossplane.io, the string for its name returned by Route53 API is \052.crossplane.io.

https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DomainNameFormat.html?shortFooter=true#domain-name-format-asterisk

Fixes #1115

I have:

  • Read and followed Crossplane's contribution process.
  • Run make reviewable test to ensure this PR is ready for review.

How has this code been tested

Ran this code against my private Route53 zone with the following yaml:

apiVersion: route53.aws.crossplane.io/v1alpha1
kind: ResourceRecordSet
metadata:
  name: 'test-dns'
  annotations:
    crossplane.io/external-name: "*.crossplane.manabu.com"
spec:
  forProvider:
    type: A
    ttl: 300
    zoneId: <ZONEID>
    resourceRecords:
    - value: 1.2.3.4
  providerConfigRef:
    name: aws-provider-config

It used to never reach the ready state.

Normal   PendingExternalResource      24m (x3 over 24m)  managed/resourcerecordset.route53.aws.crossplane.io  Waiting for external resource existence to be confirmed

After the change, it correctly reaches the ready state.

Signed-off-by: Manabu Mccloskey <manabu.mccloskey@gmail.com>
Copy link
Member

@haarchri haarchri left a comment

Choose a reason for hiding this comment

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

LGTM thanks for taking care

@haarchri haarchri merged commit 715b032 into crossplane-contrib:master Jun 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

route53 resource does not work well with wildcard '*'
2 participants