zoukankan      html  css  js  c++  java
  • 使用acme.sh签发Let's Encrypt的免费数字证书

    --------------安装----------------
    curl https://get.acme.sh | sh
    #让alias生效
    source ~/.bashrc


    -------------设置DNS API------------
    在dns运营商网站设置DNS API的API KEY/SECRET KEY
    #例如阿里云,域名所在账号登录后,进入如下页面进行设置 https://usercenter.console.aliyun.com/#/manage/ak

    # 得到key和Secret执行以下两行

    export Ali_Key="sdfsdfsdfljlbjkljlkjsdfoiwje"

    export Ali_Secret="jlsdflanljkljlfdsaklkjflsa"

    -------------申请签发证书--------------
    #可以多个域名同时申请,也可以是泛域名
    acme.sh --issue --dns dns_ali -d smallpay.cn -d *.smallpay.com

    #显示得到证书信息
    #[Thu Sep 26 12:29:40 CST 2019] Your cert is in /root/.acme.sh/*.smallpay.com/*.smallpay.com.cer
    #[Thu Sep 26 12:29:40 CST 2019] Your cert key is in /root/.acme.sh/*.smallpay.com/*.smallpay.com.key
    #[Thu Sep 26 12:29:40 CST 2019] The intermediate CA cert is in /root/.acme.sh/*.smallpay.com/ca.cer
    #[Thu Sep 26 12:29:40 CST 2019] And the full chain certs is there: /root/.acme.sh/*.smallpay.com/fullchain.cer

    -------------acme会自动添加crontab-----
    #检查下crontab,到期会自动续
    #crontab -l
    #43 0 * * * "/root/.acme.sh"/acme.sh --cron --home "/root/.acme.sh" > /dev/null

  • 相关阅读:
    PHP生成二维码并上传到七牛云
    算法入门---选择排序
    算法入门
    react入门-refs
    react入门-props.children
    react入门-组件方法、数据和生命周期
    react入门-jsx
    递归
    node的path.join 和 path.resolve的区别
    vuex的使用
  • 原文地址:https://www.cnblogs.com/suminem/p/11607003.html
Copyright © 2011-2022 走看看