jekyll+isso+leancloud切换https

编程入门 行业动态 更新时间:2024-10-09 14:20:44

jekyll+<a href=https://www.elefans.com/category/jswz/34/1729949.html style=isso+leancloud切换https"/>

jekyll+isso+leancloud切换https

前言

之前jekyll+isso使用的http协议,现在将jekyll切到https之后,发现不显示isso评论了,google一阵子之后,发现原来https的网页内如果再去请示http的资源(例如js文件)会失败。所以又不得不想办法把isso也改成https服务。这里记录一下修改步骤。

ISSO配置修改

  • host添加https名单
  • public-endpoint改为https协议(nginx代理的URL)
[general]
dbpath = /var/lib/isso/comments.db
host =://www.ferrisyu/[server]
listen = http://localhost:8090/
public-endpoint = :7000/isso

nginx配置修改

申请免费证书参考链接:用 Certbot 一键升级你的网站为 Https
自动更新证书参考链接:手把手教你在Nginx上使用CertBot
根据上面的链接指导,只要几条命令就可以自动升级到https

# 安装certbot
sudo apt-get update
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update
sudo apt-get install python-certbot-nginx# 升级到https
sudo certbot --nginx# 配置自动更新
sudo crontab -e
# 添加配置
30 2 * * 1 /usr/bin/certbot renew  >> /var/log/le-renew.log

jekyll修改

  • _config.yml中将url改成https
  • 搜索整个目录,使用http指向的本站图片、链接都改成https,一般写博客都是写的"/XXX/xxx/1.jpg",不需要指定协议,所以基本不用改。
  • 将访问ISSO接口的URL改成https

leancloud

添加https域名白名单

更多推荐

jekyll+isso+leancloud切换https

本文发布于:2024-03-11 21:31:27,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1729942.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:isso   jekyll   https   leancloud

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!