1 { stdenv, lib, fetchFromGitHub, ruby, makeWrapper, replace }:
3 stdenv.mkDerivation rec {
4 pname = "discourse-mail-receiver";
7 src = fetchFromGitHub {
9 repo = "mail-receiver";
11 sha256 = "0grifm5qyqazq63va3w26xjqnxwmfixhx0fx0zy7kd39378wwa6i";
14 nativeBuildInputs = [ replace makeWrapper ];
15 buildInputs = [ ruby ];
22 replace-literal -f -r -e /etc/postfix /run/discourse-mail-receiver .
24 cp -r receive-mail discourse-smtp-fast-rejection $out/bin/
27 wrapProgram $out/bin/receive-mail --set RUBYLIB $out/lib
28 wrapProgram $out/bin/discourse-smtp-fast-rejection --set RUBYLIB $out/lib
32 homepage = "https://www.discourse.org/";
33 platforms = platforms.linux;
34 maintainers = with maintainers; [ talyz ];
35 license = licenses.mit;
36 description = "Helper program which receives incoming mail for Discourse";