|
1. 先檢查 Apache Conf 檔案的位置
2. 打開設定檔
- sudo vim /etc/apache2/sites-enabled/wordpress.conf
复制代码
3. 參考以下
- <VirtualHost *:80>
- ServerName yourdomain.com
- Redirect permanent / [url]https://yourdomain.com/[/url]
- </VirtualHost>
- <VirtualHost _default_:443>
- ServerName yourdomain.com
- DocumentRoot /usr/local/apache2/htdocs
- SSLEngine On
- ...
- </VirtualHost>
复制代码
4. 重啟 Apache
- sudo /etc/init.d/apache2 restart
复制代码
|
|