hakyll-skeleton: converted to flake
This commit is contained in:
parent
389281c905
commit
aa6183ed0c
18
flake.lock
18
flake.lock
|
@ -1,5 +1,22 @@
|
||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
|
"hakyll-skeleton": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1656491537,
|
||||||
|
"narHash": "sha256-bC8ND81E0Sq7i+7btoSzhpCB75oHoa3eEcFvvG8XB4g=",
|
||||||
|
"ref": "consensus",
|
||||||
|
"rev": "c0df6f6abed90c66e2eff2106ce89bac0a3344db",
|
||||||
|
"revCount": 3,
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://source.jfdic.org/jfdic/hakyll-skeleton/"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"ref": "consensus",
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://source.jfdic.org/jfdic/hakyll-skeleton/"
|
||||||
|
}
|
||||||
|
},
|
||||||
"jfdic-web": {
|
"jfdic-web": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
|
@ -173,6 +190,7 @@
|
||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
|
"hakyll-skeleton": "hakyll-skeleton",
|
||||||
"jfdic-web": "jfdic-web",
|
"jfdic-web": "jfdic-web",
|
||||||
"nix": "nix",
|
"nix": "nix",
|
||||||
"nixops": "nixops",
|
"nixops": "nixops",
|
||||||
|
|
|
@ -2,6 +2,10 @@
|
||||||
description = "jfdic-ops deployment";
|
description = "jfdic-ops deployment";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
|
hakyll-skeleton = {
|
||||||
|
flake = false;
|
||||||
|
url = git+https://source.jfdic.org/jfdic/hakyll-skeleton/?ref=consensus;
|
||||||
|
};
|
||||||
jfdic-web = {
|
jfdic-web = {
|
||||||
flake = false;
|
flake = false;
|
||||||
url = git+https://source.jfdic.org/JFDIC/jfdic-web/?ref=consensus;
|
url = git+https://source.jfdic.org/JFDIC/jfdic-web/?ref=consensus;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
self,
|
self,
|
||||||
|
hakyll-skeleton,
|
||||||
jfdic-web,
|
jfdic-web,
|
||||||
nix,
|
nix,
|
||||||
nixops,
|
nixops,
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
# NixOps configuration for deploying the JFDIC website
|
# NixOps configuration for deploying the JFDIC website
|
||||||
|
{
|
||||||
{ config, pkgs, ... }:
|
self,
|
||||||
|
config,
|
||||||
let
|
inputs,
|
||||||
sources = import ../nix/sources.nix;
|
pkgs,
|
||||||
hakyll-skeleton = import sources.hakyll-skeleton { };
|
...
|
||||||
|
}: let
|
||||||
|
hakyll-skeleton = import inputs.hakyll-skeleton {};
|
||||||
webdomain = "skeleton.jfdic.org";
|
webdomain = "skeleton.jfdic.org";
|
||||||
|
|
||||||
in {
|
in {
|
||||||
|
|
||||||
environment.sessionVariables = {
|
environment.sessionVariables = {
|
||||||
LOCALE_ARCHIVE = "/run/current-system/sw/lib/locale/locale-archive";
|
LOCALE_ARCHIVE = "/run/current-system/sw/lib/locale/locale-archive";
|
||||||
};
|
};
|
||||||
|
@ -20,23 +20,23 @@ in {
|
||||||
recommendedProxySettings = true;
|
recommendedProxySettings = true;
|
||||||
recommendedTlsSettings = true;
|
recommendedTlsSettings = true;
|
||||||
virtualHosts = {
|
virtualHosts = {
|
||||||
"${webdomain}" = { # website hostname
|
"${webdomain}" = {
|
||||||
|
# website hostname
|
||||||
enableACME = true; # Use ACME certs
|
enableACME = true; # Use ACME certs
|
||||||
forceSSL = true; # Force SSL
|
forceSSL = true; # Force SSL
|
||||||
root = "${hakyll-skeleton}"; # Wesbite root
|
root = "${hakyll-skeleton}"; # Wesbite root
|
||||||
};
|
};
|
||||||
"www.${webdomain}" = { # Respect our elders :-)
|
"www.${webdomain}" = {
|
||||||
locations."/".extraConfig =
|
# Respect our elders :-)
|
||||||
"return 301 $scheme://${webdomain}$request_uri;";
|
locations."/".extraConfig = "return 301 $scheme://${webdomain}$request_uri;";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
security.acme = {
|
||||||
acceptTerms = true;
|
acceptTerms = true;
|
||||||
certs = { "${webdomain}" = { email = "admin@${webdomain}"; }; };
|
certs = {"${webdomain}" = {email = "admin@${webdomain}";};};
|
||||||
};
|
};
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
networking.firewall.allowedTCPPorts = [80 443];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue