tvl-depot/services/tazblog/default.nix
Vincent Ambo be074c6085 refactor(tazblog): Move blog configuration to envvars
The port and resource directory are now specified via environment
variables and a wrapper script is created by Nix that sets the
resource path and so on correctly.
2019-08-23 12:03:17 +01:00

12 lines
333 B
Nix

# Build configuration for the blog using plain Nix.
#
# tazblog.nix was generated using cabal2nix.
{ pkgs ? import <nixpkgs> {} }:
let tazblog = pkgs.haskell.packages.ghc865.callPackage ./tazblog.nix {};
in pkgs.writeShellScriptBin "tazblog" ''
export PORT=8000
export RESOURCE_DIR=${./static}
exec ${tazblog}/bin/tazblog
''