mirror of
https://github.com/itme-brain/nixos.git
synced 2026-03-23 16:29:42 -04:00
added systemd service
This commit is contained in:
parent
854c73624d
commit
5244e49665
1 changed files with 21 additions and 21 deletions
|
|
@ -43,28 +43,28 @@ in
|
|||
};
|
||||
|
||||
|
||||
#systemd.services.electrs = {
|
||||
# Unit = {
|
||||
# Description = "Electrs Bitcoin Indexer";
|
||||
# After = [ "network.target" "bitcoind.service" ];
|
||||
# Requires = [ "bitcoind.service" ];
|
||||
# };
|
||||
# Service = {
|
||||
# ExecStartPre = "${pkgs.coreutils}/sleep 10";
|
||||
# ExecStart = "${pkgs.electrs}/bin/electrs --conf=${conf}";
|
||||
systemd.services.electrs = {
|
||||
Unit = {
|
||||
Description = "Electrs Bitcoin Indexer";
|
||||
After = [ "network.target" "bitcoind.service" ];
|
||||
Requires = [ "bitcoind.service" ];
|
||||
};
|
||||
Service = {
|
||||
ExecStartPre = "${pkgs.coreutils}/sleep 10";
|
||||
ExecStart = "${pkgs.electrs}/bin/electrs --conf=${conf}";
|
||||
|
||||
# User = "electrs";
|
||||
# Group = "bitcoin";
|
||||
User = "electrs";
|
||||
Group = "bitcoin";
|
||||
|
||||
# Type = "simple";
|
||||
# KillMode = "process";
|
||||
# TimeoutSec = 60;
|
||||
# Restart = "always";
|
||||
# RestartSec = 60;
|
||||
# };
|
||||
# Install = {
|
||||
# WantedBy = [ "multi-user.target" ];
|
||||
# };
|
||||
#};
|
||||
Type = "simple";
|
||||
KillMode = "process";
|
||||
TimeoutSec = 60;
|
||||
Restart = "always";
|
||||
RestartSec = 60;
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "multi-user.target" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue