tangled
alpha
login
or
join now
tjh.dev
/
nixpkgs
Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
0
fork
atom
overview
issues
pulls
pipelines
nixos/amazon-ssm-agent: fix missing seelog.xml file
Anthony Roussel
2 years ago
3dd50eaa
ea71f171
+6
-3
1 changed file
expand all
collapse all
unified
split
nixos
modules
services
misc
amazon-ssm-agent.nix
+6
-3
nixos/modules/services/misc/amazon-ssm-agent.nix
···
33
33
};
34
34
35
35
config = mkIf cfg.enable {
36
36
+
# See https://github.com/aws/amazon-ssm-agent/blob/mainline/packaging/linux/amazon-ssm-agent.service
36
37
systemd.services.amazon-ssm-agent = {
37
38
inherit (cfg.package.meta) description;
38
38
-
after = [ "network.target" ];
39
39
+
after = [ "network-online.target" ];
39
40
wantedBy = [ "multi-user.target" ];
40
41
41
42
path = [ fake-lsb-release pkgs.coreutils ];
43
43
+
42
44
serviceConfig = {
43
45
ExecStart = "${cfg.package}/bin/amazon-ssm-agent";
44
46
KillMode = "process";
45
47
# We want this restating pretty frequently. It could be our only means
46
48
# of accessing the instance.
47
49
Restart = "always";
48
48
-
RestartSec = "1min";
50
50
+
RestartPreventExitStatus = 194;
51
51
+
RestartSec = "90";
49
52
};
50
53
};
51
54
···
70
73
group = "ssm-user";
71
74
};
72
75
73
73
-
environment.etc."amazon/ssm/seelog.xml".source = "${cfg.package}/seelog.xml.template";
76
76
+
environment.etc."amazon/ssm/seelog.xml".source = "${cfg.package}/etc/amazon/ssm/seelog.xml.template";
74
77
75
78
environment.etc."amazon/ssm/amazon-ssm-agent.json".source = "${cfg.package}/etc/amazon/ssm/amazon-ssm-agent.json.template";
76
79