wow
This commit is contained in:
parent
9bbceb15fd
commit
56add49b96
3 changed files with 30 additions and 2 deletions
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
{ inputs, pkgs, ... }:
|
||||
|
||||
{
|
||||
systemd.services.cfwithoutincident = {
|
||||
|
|
@ -11,13 +11,19 @@
|
|||
Type = "simple";
|
||||
User = "imnyang";
|
||||
Group = "users";
|
||||
WorkingDirectory = "/home/imnyang/git/imnyang/cfwithoutincident";
|
||||
WorkingDirectory = "/var/lib/cfwithoutincident";
|
||||
Environment = [
|
||||
"PORT=31774"
|
||||
];
|
||||
ExecStartPre = [
|
||||
"${pkgs.coreutils}/bin/cp -r ${inputs.cfwithoutincident}/. /var/lib/cfwithoutincident/"
|
||||
"${pkgs.bun}/bin/bun install --frozen-lockfile"
|
||||
];
|
||||
ExecStart = "${pkgs.bun}/bin/bun run src/index.ts";
|
||||
Restart = "always";
|
||||
RestartSec = 5;
|
||||
StateDirectory = "cfwithoutincident";
|
||||
StateDirectoryMode = "0755";
|
||||
};
|
||||
|
||||
path = [ pkgs.bun ];
|
||||
|
|
|
|||
Loading…
Reference in a new issue