From 84a5bfb7e3f4cad986c2d7567aca002a3f342579 Mon Sep 17 00:00:00 2001 From: cmspam Date: Sun, 24 Nov 2024 00:02:11 +0900 Subject: [PATCH] user/incus: Add /etc/default/incus configuration file for environment variables --- user/incus/files/envfile | 1 + user/incus/files/incus | 1 + user/incus/files/tmpfiles.conf | 1 + user/incus/template.py | 4 +++- 4 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 user/incus/files/envfile create mode 100644 user/incus/files/tmpfiles.conf diff --git a/user/incus/files/envfile b/user/incus/files/envfile new file mode 100644 index 0000000000..c3d9aee5ec --- /dev/null +++ b/user/incus/files/envfile @@ -0,0 +1 @@ +# env vars for incus diff --git a/user/incus/files/incus b/user/incus/files/incus index 1b3a4f5fd0..712fdd5d6b 100644 --- a/user/incus/files/incus +++ b/user/incus/files/incus @@ -1,3 +1,4 @@ type = process command = /usr/bin/incusd --group _incus-admin --syslog depends-on = local.target +env-file = /etc/default/incus diff --git a/user/incus/files/tmpfiles.conf b/user/incus/files/tmpfiles.conf new file mode 100644 index 0000000000..e6147e251b --- /dev/null +++ b/user/incus/files/tmpfiles.conf @@ -0,0 +1 @@ +C /etc/default/incus 0644 root root - /usr/share/incus/envfile diff --git a/user/incus/template.py b/user/incus/template.py index 606eb59367..beb9a34ebf 100644 --- a/user/incus/template.py +++ b/user/incus/template.py @@ -1,6 +1,6 @@ pkgname = "incus" pkgver = "6.7.0" -pkgrel = 1 +pkgrel = 2 build_style = "go" make_build_args = ["./cmd/..."] make_check_args = ["-skip", "TestConvertNetworkConfig", "./..."] @@ -62,6 +62,8 @@ def post_install(self): self.install_service(self.files_path / "incus") self.install_service(self.files_path / "incus-user") self.install_sysusers(self.files_path / "sysusers.conf") + self.install_tmpfiles("^/tmpfiles.conf") + self.install_file("^/envfile", "usr/share/incus") @subpackage("incus-client")