gpt4 book ai didi

ubuntu - dokku 和 digital ocean 的 ssl

转载 作者:太空宇宙 更新时间:2023-11-03 13:03:48 25 4
gpt4 key购买 nike

如果我使用 example.com 上的 dokku 将一个名为 test 的新应用程序推送到我的 Droplet,这里是链接:

http://test.example.com

我看过有关如何为这个特定应用程序添加 SSL 的教程。 (即 https://launchbylunch.com/posts/2014/Jan/23/blog-tech-stack/ )。

我如何通过 digital ocean droplet 进行设置,以便使用 dokku 推送的每个应用程序都启用了 ssl?这甚至可能吗?

最佳答案

根据官方 Dokku readme (v0.2.3):

All Subdomains

To enable TLS connections for all your applications at once you will need a wildcard TLS certificate.

To enable TLS across all apps, copy or symlink the .crt/.pem and .key files into the /home/dokku/tls folder (create this folder if it doesn't exist) as server.crt and server.key respectively. Then, enable the certificates by editing /etc/nginx/conf.d/dokku.conf and uncommenting these two lines (remove the #):

ssl_certificate /home/dokku/tls/server.crt;

ssl_certificate_key /home/dokku/tls/server.key;

The nginx configuration will need to be reloaded in order for the updated TLS configuration > to be applied. This can be done either via the init system or by re-deploying the application. Once TLS is enabled, the application will be accessible by https:// (redirection from http:// is applied as well).

Note: TLS will not be enabled unless the application's VHOST matches the certificate's name. (i.e. if you have a cert for *.example.com TLS won't be enabled for something.example.org or example.net)

免责声明:我自己没有测试过,这只是来自官方文档。

关于ubuntu - dokku 和 digital ocean 的 ssl,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24179664/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com