summaryrefslogtreecommitdiffstats
path: root/recipes-connectivity/kuksa-val/kuksa-databroker_git.bb
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2023-05-30 16:52:16 -0400
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2023-05-31 09:55:31 +0000
commit1fb690465a3704a7a492495ff2606c4edb46b902 (patch)
treebcbb72bfab3575877b5df727fac8a973166ce110 /recipes-connectivity/kuksa-val/kuksa-databroker_git.bb
parenta87c7d82262ba9e88f589acfa8c92f2b6076c0eb (diff)
Add KUKSA.val databroker
Add a recipe for the KUKSA.val databroker, a Rust implementation of a VSS server with gRPC APIs, and add it to the images that currently have the C++ kuksa-val server to ease further integration development. Since the databroker listens for gRPC API requests on a different port than the C++ server, there is no conflict during this period. Users wanting to drive CAN data into the databroker for testing will have to manually update the kuksa-dbc-feeder configuration during this interim period. Changes: - Bump common KUKSA.val SRCREV to pick up some improvements. - Add kuksa-databroker recipe to build the databroker. - Add kuksa-databroker-agl recipe to install AGL-specific configuration for the databroker, similar to what has previously been done with kuksa-val-agl for the C++ server. - Add missing branch node declarations in the AGL VSS overlay, as the databroker VSS parser is stricter and treats their absence as an error. - Add the kuksa-databroker, kuksa-databroker-agl, and the kuksa-databroker-cli packages to the appropriate packagegroups and images. Some follow up work will factor out a packagegroup for the KUKSA.val packages to make future changes easier. Bug-AGL: SPEC-4762 Change-Id: Ie7837b7e42a2283914adc913b75639fcb83029a6 Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Diffstat (limited to 'recipes-connectivity/kuksa-val/kuksa-databroker_git.bb')
-rw-r--r--recipes-connectivity/kuksa-val/kuksa-databroker_git.bb49
1 files changed, 49 insertions, 0 deletions
diff --git a/recipes-connectivity/kuksa-val/kuksa-databroker_git.bb b/recipes-connectivity/kuksa-val/kuksa-databroker_git.bb
new file mode 100644
index 000000000..f1d829c60
--- /dev/null
+++ b/recipes-connectivity/kuksa-val/kuksa-databroker_git.bb
@@ -0,0 +1,49 @@
+SUMMARY = "KUKSA.val databroker, the KUKSA Vehicle Abstraction Layer"
+#DESCRIPTION = "KUKSA.val provides a COVESA VSS data model describing data in a vehicle."
+HOMEPAGE = "https://github.com/eclipse/kuksa.val"
+BUGTRACKER = "https://github.com/eclipse/kuksa.val/issues"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2b42edef8fa55315f34f2370b4715ca9 \
+"
+
+DEPENDS = "protobuf-native grpc-native"
+
+require kuksa-val.inc
+
+require ${BPN}-crates.inc
+
+SRC_URI += "file://kuksa-databroker.service"
+
+S = "${WORKDIR}/git"
+
+inherit cargo systemd useradd
+
+SYSTEMD_SERVICE:${PN} = "${BPN}.service"
+
+USERADD_PACKAGES = "${PN}"
+USERADDEXTENSION = "useradd-staticids"
+GROUPADD_PARAM:${PN} = "-g 900 kuksa ;"
+USERADD_PARAM:${PN} = "--system -g 900 -u 900 -o -d / --shell /bin/nologin kuksa ;"
+
+do_install:append() {
+ if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+ install -d ${D}${systemd_system_unitdir}
+ install -m 0644 ${WORKDIR}/${BPN}.service ${D}${systemd_system_unitdir}
+ fi
+
+ # Install gRPC API protobuf files
+ install -d ${D}${includedir}
+ cp -dr ${S}/kuksa_databroker/proto/sdv ${D}${includedir}
+}
+
+PACKAGE_BEFORE_PN += "${PN}-cli"
+
+FILES:${PN} += "${systemd_system_unitdir} ${datadir}"
+
+FILES:${PN}-cli = "${bindir}/databroker-cli"
+
+# The upstream Cargo.toml builds optimized and stripped binaries, for
+# now disable the QA check as opposed to tweaking the configuration.
+INSANE_SKIP:${PN} = "already-stripped"
+INSANE_SKIP:${PN}-cli = "already-stripped"