mirror of
https://github.com/dehydrated-io/dehydrated.git
synced 2026-01-11 22:30:44 +01:00
Add example for using DNS-01 challenge #48
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @jmreicha on GitHub (Jan 31, 2016).
I am new to LE in general and while the description for using the challenge type is nice, it would be helpful to someone new to have an example usage.
@germeier commented on GitHub (Jan 31, 2016):
My example from my initial PR:
b6611a7d05/hook-dns-01.sh.exampleI still think an examples section in the wiki would come in handy.
@lukas2511 commented on GitHub (Jan 31, 2016):
@germeier the wiki is now writable (again), if you want you can add some examples
@germeier commented on GitHub (Jan 31, 2016):
Added my example script to the wiki: https://github.com/lukas2511/letsencrypt.sh/wiki/Example-hook-script-using-dns-01-with-nsupdate
@jmreicha commented on GitHub (Jan 31, 2016):
Nice, thanks. Maybe this can get a link in the readme?
@asimihsan commented on GitHub (Feb 1, 2016):
I've successfully used the following hook script to do the DNS challenge on Route53:
https://gist.github.com/asimihsan/d8d8f0f10bdc85fc6f8a
The idea is simple: you need to add the token as a TXT record to
_acme-challenge.#{domain}.. However, a) this code isn't refactored very well, and b) on lines 19 and 45 you get the hosted zone with the name the same as the requested domain. Hence it won't work as-is if you request e.gsub.domain.com, since you need to search fordomain.com.If you think this script is useful I can refactor it and make it more resilient to work as-is for subdomains.
@lukas2511 commented on GitHub (Feb 1, 2016):
Added a wiki page with links to those examples: https://github.com/lukas2511/letsencrypt.sh/wiki/Examples-for-DNS-01-hooks
@AnalogJ commented on GitHub (Feb 5, 2016):
Hey @lukas2511,
I created a simple library called lexicon that lets you manipulate DNS records on various cloud DNS providers in a standardized way. It was built specifically for use with letsencrypt.sh and has an example cloudflare dns-01 hook file based off of @germeier's work. To use a different provider all you need to do is change 1 line in the example hook file.
Currently it only supports Cloudflare and PointHQ, but I'm happy to merge PR's for additional providers.
Thanks for letsencrypt.sh btw, I'm a huge fan.
@YasharF commented on GitHub (Nov 1, 2016):
Did lexicon or other integration for automating dns-01 challenge get added at some point?
@AnalogJ commented on GitHub (Nov 3, 2016):
Hey @YasharF
It doesn't require any changes to
dehydratedto support automated dns-01 challenges, just a hook file that callslexicon.I wrote a blog post which fully explains how to get
lexiconto work withdehydrated(though its a bit outdated now). Thelexiconrepo includes an up-to-date Dockerfile which installsdehydrated, and configures both correctly. If you still need help feel free to open an issue in the lexicon repo