chilts / nice-route53

A nicer API to Amazon's Route53.
Apache License 2.0
37 stars 20 forks source link

Can I delete a zone with using nice-route53? #13

Open basharov opened 7 years ago

basharov commented 7 years ago

I can create and update zones with this module but I couldn't find functions to delete an existing zone. Is there a way to delete a zone in the current version? Thanks!

chilts commented 7 years ago

Wow, yeah, perhaps not. All I can see is the ability to delete a record, but not a zone. :) @basharov Are you happy to try a PR with the feature, or maybe @leorossi or I can take a look sometime.

leorossi commented 7 years ago

NIce point! Will have a look at that soon but in meanwhile @basharov you can issue a PR!

leorossi commented 7 years ago

@chilts I have started implementing this feature, you can find the code here https://github.com/leorossi/nice-route53/tree/feature/delete-hosted-zone

I have some issues in testing with tape and nock I am getting this error while trying to mock the DELETE request

{ type: 'NetworkingError',
  code: 500,
  msg: 'Nock: No match for request DELETE https://route53.amazonaws.com/2013-04-01/hostedzone/Z1PA6795UKMFR9 ' }

Any clue?

chilts commented 7 years ago

Nothing comes to mind at the moment, however I can take a look in a couple of hours or so. :) Thanks for having a go at this.