Previously, `http://` scheme was hard coded into the caddy config if
`webserver = "caddy"` was chosen. This is fine for local testing, but is
problematic if you want your nixos host to be public facing.
In the public facing case, you generally want to be using TLS. But since
the wordpress module generates the caddyfile rule, the user's nixos
config cannot easily change it to also allow https.
An alternative would be to reverse proxy an https rule to the generated
http rule, but that's somewhat questionable as there's not an internal
http endpoint to proxy to. It might be possible but I couldn't figure
it out.
So simplify by omitting the scheme. This causes caddy to use https by
default and 301 redirect any http requests to the https endpoint. Caddy
will just do the right thing if it's being hosted on a local/internal
hostname (self sign certificates).
This should be backwards compatible with previous default if users are
using reasonable browsers/tools.
Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
An installer tests exacerbates the distribution packaging but in the
case of NixOS: the Nix package manager implementation.
As part of our classical release management process, the Lix team tests
whether a NixOS system installs just fine with Lix or not.
To avoid bloating the CI needlessly and keeping it simple, we only
introduce it on the simple variant and give a general way to pipe a Nix
implementation inside of an installer test.
Change-Id: I781da14475867dc2d946b740bad10af5de79ec5a
Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
Currently failing with
error: cannot coerce a set to a string: { __functionArgs = «thunk»; __functor = «thunk»; }
This comes from the `extraTests` option I added to the test modules to
compose certain tests a little nicer. It's of type
either (functionTo ...) str
and it seems like the `functionTo` part now returns a functor (i.e. an
attr-set that can be invoked as function). This is caught by
`lib.isFunction`, but `builtins.isFunction` returns `false`.
Hence, switching to the former fixes this.