On 14 October 2016 at 20:06, Stefan Huchler <stefan.huch...@mail.de> wrote: > Hello Bjorn, > > thanks that looks interesting, worked and as easy as I expect it from > nixos :) > > One more thing how difficult would it be to add https?
The most difficult part (IMHO) is getting the certificate : -) I use something like: services.lighttpd.extraConfig = '' # Lighttpd SSL/HTTPS documentation: # http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_SSL $HTTP["host"] == "myserver.example" { $SERVER["socket"] == ":443" { ssl.engine = "enable" ssl.pemfile = "/etc/lighttpd/certs/myserver.example.pem" ssl.ca-file = "/etc/lighttpd/certs/1_Intermediate.crt" } # Force https scheme for nextcloud $HTTP["scheme"] == "http" { $HTTP["url"] =~ "^/nextcloud" { url.redirect = ("^/.*" => "https://myserver.example$0") } } } ''; You can get free certificate from startssl.com (that's what I use). Best regards, Bjørn Forsman _______________________________________________ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev