Merge pull request #165788 from WolfangAukang/sslmate-agent
This commit is contained in:
commit
e705e58950
32
nixos/modules/services/security/sslmate-agent.nix
Normal file
32
nixos/modules/services/security/sslmate-agent.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.services.sslmate-agent;
|
||||
|
||||
in {
|
||||
meta.maintainers = with maintainers; [ wolfangaukang ];
|
||||
|
||||
options = {
|
||||
services.sslmate-agent = {
|
||||
enable = mkEnableOption "sslmate-agent, a daemon for managing SSL/TLS certificates on a server";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = with pkgs; [ sslmate-agent ];
|
||||
|
||||
systemd = {
|
||||
packages = [ pkgs.sslmate-agent ];
|
||||
services.sslmate-agent = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
ConfigurationDirectory = "sslmate-agent";
|
||||
LogsDirectory = "sslmate-agent";
|
||||
StateDirectory = "sslmate-agent";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
40
pkgs/development/tools/sslmate-agent/default.nix
Normal file
40
pkgs/development/tools/sslmate-agent/default.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{ lib, stdenv, fetchurl, dpkg, autoPatchelfHook }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "sslmate-agent";
|
||||
version = "1.99.11";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://packages.sslmate.com/debian/pool/sslmate2/s/sslmate-client/${pname}_${version}-1_amd64.deb";
|
||||
sha256 = "sha256-LBiZI0pGAFWnvTigEhtkhHq4FGdbYiMzjLheMuP0YTU=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
dpkg
|
||||
autoPatchelfHook
|
||||
];
|
||||
|
||||
unpackCmd = ''
|
||||
dpkg-deb -x ${src} ./sslmate-agent-${pname}
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
# Not moving etc because it only contains init.rd setttings
|
||||
mv usr $out
|
||||
mv lib $out
|
||||
|
||||
substituteInPlace $out/lib/systemd/system/sslmate-agent.service \
|
||||
--replace "/usr/s" "$out/"
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Daemon for managing SSL/TLS certificates on a server";
|
||||
homepage = "https://sslmate.com/";
|
||||
license = licenses.unfree;
|
||||
maintainers = with maintainers; [ wolfangaukang ];
|
||||
};
|
||||
}
|
|
@ -10253,6 +10253,8 @@ with pkgs;
|
|||
|
||||
sslmate = callPackage ../development/tools/sslmate { };
|
||||
|
||||
sslmate-agent = callPackage ../development/tools/sslmate-agent { };
|
||||
|
||||
sshoogr = callPackage ../tools/networking/sshoogr { };
|
||||
|
||||
ssmtp = callPackage ../tools/networking/ssmtp { };
|
||||
|
|
Loading…
Reference in New Issue
Block a user