From 29d65643894b5bd922cb2e425cd71fc42e4f257d Mon Sep 17 00:00:00 2001 From: To-om Date: Mon, 12 Apr 2021 08:20:31 +0200 Subject: [PATCH] #1954 Add default file for service environment --- package.sbt | 1 + package/thehive.default | 4 ++++ package/thehive.service | 3 ++- 3 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 package/thehive.default diff --git a/package.sbt b/package.sbt index bc6a06977a..a8ae03beb4 100644 --- a/package.sbt +++ b/package.sbt @@ -40,6 +40,7 @@ linuxPackageMappings ++= Seq( file("package/thehive.service") -> "/usr/lib/systemd/system/thehive.service" ).withPerms("644"), packageMapping( + file("package/thehive.default") -> "/etc/default/thehive", file("conf/application.sample.conf") -> "/etc/thehive/application.conf", file("package/logback.xml") -> "/etc/thehive/logback.xml", file("package/logback-migration.xml") -> "/etc/thehive/logback-migration.xml" diff --git a/package/thehive.default b/package/thehive.default new file mode 100644 index 0000000000..d72cf7a890 --- /dev/null +++ b/package/thehive.default @@ -0,0 +1,4 @@ +# Environment File for TheHive + +# JAVA_OPTS for TheHive service can be set here +#JAVA_OPTS="" diff --git a/package/thehive.service b/package/thehive.service index bb93d45540..77191ef248 100644 --- a/package/thehive.service +++ b/package/thehive.service @@ -5,6 +5,7 @@ Wants=network-online.target After=network-online.target [Service] +EnvironmentFile=-/etc/default/thehive WorkingDirectory=/opt/thehive User=thehive @@ -34,4 +35,4 @@ SendSIGKILL=no SuccessExitStatus=143 [Install] -WantedBy=multi-user.target \ No newline at end of file +WantedBy=multi-user.target