certbot / certbot

Certbot is EFF's tool to obtain certs from Let's Encrypt and (optionally) auto-enable HTTPS on your server. It can also act as a client for any other CA that uses the ACME protocol.
Other
31.58k stars 3.4k forks source link

Make all plugins available via Homebrew #5680

Open JasonLunn opened 6 years ago

JasonLunn commented 6 years ago

My operating system is (include version): macOS High Sierra 10.13.3

I installed Certbot with (certbot-auto, OS package manager, pip, etc): homebrew

I ran this command and it produced this output: certbot plugins

-------------------------------------------------------------------------------
* apache
Description: Apache Web Server plugin - Beta
Interfaces: IAuthenticator, IInstaller, IPlugin
Entry point: apache = certbot_apache.entrypoint:ENTRYPOINT

* nginx
Description: Nginx Web Server plugin - Alpha
Interfaces: IAuthenticator, IInstaller, IPlugin
Entry point: nginx = certbot_nginx.configurator:NginxConfigurator

* standalone
Description: Spin up a temporary webserver
Interfaces: IAuthenticator, IPlugin
Entry point: standalone = certbot.plugins.standalone:Authenticator

* webroot
Description: Place files in webroot directory
Interfaces: IAuthenticator, IPlugin
Entry point: webroot = certbot.plugins.webroot:Authenticator
-------------------------------------------------------------------------------

Certbot's behavior differed from what I expected because:

dns-route53 and other plugins found in the master branch were not available.

Discussion on Homebrew/homebrew-core/issues/18227 suggests that the Homebrew maintainers have an objection to the dependency management that would be required to solve this completely on their end.

sydneyli commented 6 years ago

Thanks! With the upcoming ACMEv2 release, we expect the DNS plugins to become more popular, and are working on documenting/packaging them properly. I'm not sure we want to push the maintainers to package the DNS plugins together with everything else, since they introduce many large dependencies (#4767).

We usually package plugins separately and are currently trying to get our DNS plugins packaged for Debian/Fedora (#5368). The answer here for homebrew might be to push for an installation option like --with-dns-plugins.

JasonLunn commented 6 years ago

I don't have a strong preference about whether or not it is in one package or many (as I'm used to on CentOS) but right now there is now way to get a packaged version of the route53 plugin via homebrew and that's what I'm most interested in getting solved.

sydneyli commented 6 years ago

For now, you can use the formula in Homebrew/homebrew-core#18228 (or use pip install, but assuming you'd prefer brew)

JasonLunn commented 6 years ago

I'm a homebrew user, not a homebrew developer, and have never built a formula from source before. Is it trivial?

sydneyli commented 6 years ago

brew edit certbot should pull up the relevant formula in a text editor, where you can update it.

DomT4 commented 6 years ago

I'm not a Homebrew maintainer any more, for those of you around this project who remember me as being one, and I throw in that caveat as a this might not necessarily get accepted note, but I've opened https://github.com/Homebrew/homebrew-core/pull/24982.

alanivey commented 6 years ago

The certbot formula in Homebrew installs certbot in a virtualenv. This means it can be "extended":

$( brew --prefix certbot )/libexec/bin/python -m pip install certbot-dns-route53

Verify by running certbot plugins before and after.

This would need to be run anytime brew upgrade certbot is run, so it's not ideal for the long-term.

dnozay commented 4 years ago

https://github.com/Homebrew/homebrew-core/pull/47619 @alebcay has changed the homebrew formula, there isn't a virtualenv anymore.

pip3 install --prefix=$(brew --prefix certbot)/libexec/vendor certbot-dns-google
appenz commented 2 years ago

Looks like it's a virtenv again. Command from @alanivey worked for me, the one from @dnozay did not.

oemden commented 2 years ago

The certbot formula in Homebrew installs certbot in a virtualenv. This means it can be "extended":

$( brew --prefix certbot )/libexec/bin/pip install certbot-dns-route53

Verify by running certbot plugins before and after.

This would need to be run anytime brew upgrade certbot is run, so it's not ideal for the long-term.

Thank you very much !!! works like a charm with certbot-dns-ovh on BigSur with http and php installed via homebrew.

github-actions[bot] commented 1 year ago

We've made a lot of changes to Certbot since this issue was opened. If you still have this issue with an up-to-date version of Certbot, can you please add a comment letting us know? This helps us to better see what issues are still affecting our users. If there is no activity in the next 30 days, this issue will be automatically closed.

ninepints commented 1 year ago

Still a problem as of this writing. (I don't have strong feelings on how plugins are installed, but some kind of official guidance for people who installed Certbot through Homebrew would be good - this thread is the most authoritative information I've found so far. The Certbot website has incorrect instructions for macOS right now.)

mikewyer commented 9 months ago

pip is not installed as a command in libexec/bin any more.

$(brew --prefix certbot)/libexec/bin/python -mpip install certbot-dns-google

seems to do the trick

alanivey commented 9 months ago

Good catch @mikewyer; I updated my comment accordingly.

RafalSkolasinski commented 6 days ago

Worked like charm for dns with digitalocean

$(brew --prefix certbot)/libexec/bin/python3 -m pip install certbot-dns-digitalocean