zoukankan      html  css  js  c++  java
  • Windows下Apache配置https

    1、将mycert.crt 和mycert.key 文件复制到Apache 一级目录中

    2、httpd.conf 开启相关的loadModule
    LoadModule ssl_module modules/mod_ssl.so 去掉前面#号 其他需要开启的 根据错误提示逐个开启
    3、http-vhost.conf 加入配置
    #原始配置 可以保留
    listen 80
    <VirtualHost *:80>
       DocumentRoot "D:/website/seo/public"
       ServerName www.test.com
      DirectoryIndex index.php index.html
      <Directory "D:/website/seo/public">
         Options FollowSymLinks
         AllowOverride All
         Order allow,deny
         Allow from all
       </Directory>
        CustomLog "logs/test.log" combined
    </VirtualHost>
    
    #https配置
    listen 443
    <VirtualHost *:443>
       DocumentRoot "D:/website/seo/public"
       ServerName www.test.com
       SSLEngine on
       SSLCertificateFile mycert.crt
       SSLCertificateKeyFile mycert.key
      DirectoryIndex index.php index.html
      <Directory "D:/website/seo/public">
         Options FollowSymLinks
         AllowOverride All
         Order allow,deny
         Allow from all
       </Directory>
        CustomLog "logs/test.log" combined
    </VirtualHost>
     
    4、重启Apache
     

  • 相关阅读:
    wifi 与 以太网 以及 修改网络查看网络
    git 与 gitHub 与 gitLab ,git常用5个命令
    花生壳
    诗词古文
    基金龙虎榜
    osm_mano安装
    db2快速删除大表数据(亲测可用)
    行列转换
    DB2表空间
    表分区,和分表区别
  • 原文地址:https://www.cnblogs.com/guliang/p/11820550.html
Copyright © 2011-2022 走看看