Skip to content

Instantly share code, notes, and snippets.

@sorki
Created May 1, 2020 07:40
Show Gist options
  • Select an option

  • Save sorki/ab7ed0838bc8d92247f4a194c1c624e9 to your computer and use it in GitHub Desktop.

Select an option

Save sorki/ab7ed0838bc8d92247f4a194c1c624e9 to your computer and use it in GitHub Desktop.
Discourse test
{ config, pkgs, lib, ... }:
let
nixpkgs = /home/srk/git/nixpkgs;
in
{
imports =
[
"${nixpkgs}/nixos/modules/services/web-apps/discourse.nix"
];
nixpkgs.overlays = [
(self: super: {
discourse = super.callPackage "${nixpkgs}/pkgs/servers/web-apps/discourse" { };
discourse-mail-receiver = super.callPackage "${nixpkgs}/pkgs/servers/web-apps/discourse/mail-receiver.nix" { };
})
];
networking.extraHosts = ''
127.0.0.1 discourse.xmpl
'';
services.discourse = {
enable = true;
hostName = "discourse.xmpl";
database = {
name = "dd";
createLocally = true;
passwordFile = "/run/keys/discourse-dbpassword";
};
mail = {
enable = true;
apiKeyFile = "/run/keys/discourse-mailer-api-key";
};
web = {
enable = true;
https = false;
workers = 2;
};
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment