diff options
-rw-r--r-- | nixos/socrates/configuration.nix | 5 | ||||
-rw-r--r-- | website/sandbox/chord-drill-sergeant/default.nix | 24 | ||||
-rw-r--r-- | website/sandbox/chord-drill-sergeant/src/Main.elm | 2 |
3 files changed, 30 insertions, 1 deletions
diff --git a/nixos/socrates/configuration.nix b/nixos/socrates/configuration.nix index fb0964aaea37..8d3149df8a05 100644 --- a/nixos/socrates/configuration.nix +++ b/nixos/socrates/configuration.nix @@ -177,6 +177,11 @@ in { enableACME = true; root = briefcase.website.sandbox; }; + "learnpianochords.app" = { + addSSL = true; + enableACME = true; + root = briefcase.website.sandbox.chord-drill-sergeant; + }; }; }; diff --git a/website/sandbox/chord-drill-sergeant/default.nix b/website/sandbox/chord-drill-sergeant/default.nix new file mode 100644 index 000000000000..7ea92c29f5c1 --- /dev/null +++ b/website/sandbox/chord-drill-sergeant/default.nix @@ -0,0 +1,24 @@ +{ pkgs, ... }: + +pkgs.stdenv.mkDerivation { + name = "learn-piano-chords"; + src = ./.; + buildInputs = with pkgs; [ + elmPackages.elm + nodejs + ]; + outputHashMode = "recursive"; + outputHashAlgo = "sha256"; + outputHash = "0diya7q8ird56jsbf2p49fyvldsay6m9z251zr2rq1i4qs7idy0j"; + phases = [ "unpackPhase" "buildPhase" ]; + buildPhase = '' + export NIX_REDIRECTS=/etc/protocols=${pkgs.iana-etc}/etc/protocols + export LD_PRELOAD=${pkgs.libredirect}/lib/libredirect.so + export SYSTEM_CERTIFICATE_PATH=${pkgs.cacert}/etc/ssl/certs + + mkdir -p $out + cp index.html $out + elm make src/Main.elm --optimize --output=$out/elm.js + npx tailwindcss build index.css -o $out/output.css + ''; +} diff --git a/website/sandbox/chord-drill-sergeant/src/Main.elm b/website/sandbox/chord-drill-sergeant/src/Main.elm index c4c7a36653a2..054d318a08b1 100644 --- a/website/sandbox/chord-drill-sergeant/src/Main.elm +++ b/website/sandbox/chord-drill-sergeant/src/Main.elm @@ -123,7 +123,7 @@ init = , whitelistedKeys = keys , selectedChord = Nothing , isPaused = True - , tempo = 30 + , tempo = 20 , firstNote = firstNote , lastNote = lastNote , view = Preferences |