summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNaoto Yamaguchi <naoto.yamaguchi@aisin.co.jp>2023-05-02 23:46:23 +0900
committerNaoto Yamaguchi <naoto.yamaguchi@aisin.co.jp>2023-05-09 08:13:10 +0900
commit05e6e4c383362e5c871759a1a4c625643b359a8f (patch)
tree17f9ca2997a3c2b3e7c751dac417005ec92cd804
parentc17270bbef3959bc7dbfdf20f68d2a7f70bb818a (diff)
Initial support for AGL Container Manager
The AGL Instrument Cluster container integration require to container management daemon to support embedded use case such as lifecycle, many device and other. AGL IC-EG is already starting development for that daemon. This patch is initial support for that container management daemon. Bug-AGL: SPEC-4777 Change-Id: I02055c45dd53a80fc6d5ef0ab2c2206c6c0feae2 Signed-off-by: Naoto Yamaguchi <naoto.yamaguchi@aisin.co.jp>
-rw-r--r--meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.json8
-rw-r--r--meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.service11
-rw-r--r--meta-agl-ic-container/recipes-container/container-manager/container-manager_git.bb46
3 files changed, 65 insertions, 0 deletions
diff --git a/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.json b/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.json
new file mode 100644
index 00000000..31f5ddec
--- /dev/null
+++ b/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.json
@@ -0,0 +1,8 @@
+{
+ "configdir": "/opt/container/conf/",
+ "etherbridge": [
+ {
+ "name": "lxcbr0"
+ }
+ ]
+}
diff --git a/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.service b/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.service
new file mode 100644
index 00000000..50edafcc
--- /dev/null
+++ b/meta-agl-ic-container/recipes-container/container-manager/container-manager/container-manager.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=AGL Container Manager
+After=drm-lease-manager.service lxc-net.service multi-user.target
+Wants=drm-lease-manager.service lxc-net.service multi-user.target
+
+[Service]
+Type=notify
+ExecStart=/usr/bin/containermanager
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-agl-ic-container/recipes-container/container-manager/container-manager_git.bb b/meta-agl-ic-container/recipes-container/container-manager/container-manager_git.bb
new file mode 100644
index 00000000..41f75d4d
--- /dev/null
+++ b/meta-agl-ic-container/recipes-container/container-manager/container-manager_git.bb
@@ -0,0 +1,46 @@
+SUMMARY = "AGL Container Manager"
+DESCRIPTION = "AGL Container Manager for AGL Instrument Cluster."
+AUTHOR = "Naoto Yamaguchi/ AGL Instrument Cluster Expert Group"
+HOMEPAGE = "https://github.com/AGLExport/container-manager"
+BUGTRACKER = "https://github.com/AGLExport/container-manager/issues"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=89aea4e17d99a7cacdbeed46a0096b10"
+
+DEPENDS = "systemd libmnl cjson lxc util-linux"
+
+PV = "0.1.0+rev${SRCPV}"
+
+SRC_URI = " \
+ git://github.com/AGLExport/container-manager.git;branch=staging2;protocol=https \
+ file://container-manager.service \
+ file://container-manager.json \
+ "
+SRCREV = "e516cfeca7859a74a47155ab77d4b1610cae6617"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig systemd features_check
+
+REQUIRED_DISTRO_FEATURES = "systemd"
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE:${PN} = "container-manager.service"
+SYSTEMD_AUTO_ENABLE:${PN} = "enable"
+
+do_install:append() {
+ install -d ${D}/opt/container/conf/
+ install -d ${D}/opt/container/guests/
+
+ install -d ${D}${systemd_system_unitdir}
+ install -m 0644 ${WORKDIR}/container-manager.service ${D}${systemd_system_unitdir}/
+
+ install -d ${D}${sysconfdir}
+ install -m 0644 ${WORKDIR}/container-manager.json ${D}${sysconfdir}/
+}
+
+FILES:${PN} += " \
+ ${systemd_system_unitdir}/* \
+ ${sysconfdir}/* \
+ /opt/container/conf \
+ /opt/container/guests \
+ "