简介
很长时间之前写过小内存安装Wordpress的文章:https://www.cokemine.com/64mb-vps-wp.html,这里使用的Lighttpd,为了让它更有B格,我们也可以给它装上SSL
配置
$SERVER["socket"] == ":443" {
ssl.engine = "enable"
ssl.pemfile = "/etc/lighttpd/ssl/kms.pem"
$HTTP["host"] =~ "kms.aptx.xin" {
server.document-root = "/home/wwwroot/kms/public"
accesslog.filename = "/var/log/lighttpd/kms/access.log"
server.error-handler-404 = "/404.html"
}
}
$HTTP["scheme"] == "http" {
# capture vhost name with regex conditiona -> %0 in redirect pattern
# must be the most inner block to the redirect rule
$HTTP["host"] =~ ".*" {
url.redirect = (".*" => "https://%0$0")
}
}
文章评论