LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   SSL on Lighttpd - 404 errors (https://www.linuxquestions.org/questions/linux-server-73/ssl-on-lighttpd-404-errors-4175482112/)

Joe of Loath 10-25-2013 06:43 AM

SSL on Lighttpd - 404 errors
 
Hey there

Just installed an SSL certificate on my Lighttpd server (Going to install a wiki for a project I'm working on). The certificate works fine, and I can connect with a secured connection to https://*localIP*. However, all I get is a 404 error.

lighttpd.conf:

Code:

server.modules = (
        "mod_access",
        "mod_alias",
        "mod_compress",
        "mod_redirect",
#      "mod_rewrite",
)

server.document-root        = "/data"
server.upload-dirs          = ( "/var/cache/lighttpd/uploads" )
server.errorlog            = "/var/log/lighttpd/error.log"
server.pid-file            = "/var/run/lighttpd.pid"
server.username            = "www-data"
server.groupname            = "www-data"

index-file.names            = ( "index.php", "index.html",
                                "index.htm", "default.htm",
                              " index.lighttpd.html" )

url.access-deny            = ( "~", ".inc" )

static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )

## Use ipv6 if available
#include_shell "/usr/share/lighttpd/use-ipv6.pl"

dir-listing.encoding        = "utf-8"
server.dir-listing          = "enable"

compress.cache-dir          = "/var/cache/lighttpd/compress/"
compress.filetype          = ( "application/x-javascript", "text/css", "text/html", "text/plain" )

include_shell "/usr/share/lighttpd/create-mime.assign.pl"
include_shell "/usr/share/lighttpd/include-conf-enabled.pl"

$SERVER["socket"] == "xx.xx.xx.xx:443" {
server.document-root = "/home/lighttpd/xx.org"
ssl.engine = "enable"
ssl.pemfile = "/etc/lighttpd/ssl/xx.org/server.pem"
server.name = "xx.org"
##server.document-root = "/data/"
}

I assumed it was a document root issue, so I set it but it complained about duplication.

Pretty sure I've done something stupid but I'm not totally sure what (obviously).

Thanks!

Joe of Loath 10-25-2013 02:39 PM

OK, just realised I'm an idiot. Config file I copypasta'd from had a document root setting alreadt in it.


All times are GMT -5. The time now is 02:45 PM.