Skip to content

Commit

Permalink
webos: telegraf=r5 com.webos.service.sdkagent=13
Browse files Browse the repository at this point in the history
:Release Notes:
Change default config directory of telegraf

:Detailed Notes:
telegraf: r4..r5
Telegraf change default config directory
FROM /etc/telegraf/telegraf.d
TO /var/lib/com.webos.service.sdkagent/telegraf.d

com.webos.service.sdkagent: submissions/12..submissions/13
be1ca23 Remove some debug logs and
        refactor intervalProcess_handle()

:Testing Performed:
Test completed on raspberrypi4-64, qemux86-64 locally
http://tasreport.lge.com/rs/#/details/667e7cf2e6a3df052e92891a
http://tasreport.lge.com/rs#/details/667e8735e6a3df052e92891d

:QA Notes:
NA

:Issues Addressed:
[WRQ-29680] CCC: telegraf=r5 com.webos.service.sdkagent=13
[WRQ-27707] Apply new config-directory for plugins in telegraf

Cherry-picked-from-commit: 00a1f8bdb458fed5d3b7d3ee34abe414fc3e78e3
Cherry-picked-from-branch:
  • Loading branch information
hung14.nguyen authored and ywbyun0815 committed Oct 26, 2024
1 parent dae7590 commit 40cf609
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
From 2378ff5c575eac3a4eb2c90efb0d10cf08ccf1b1 Mon Sep 17 00:00:00 2001
From: "hung14.nguyen" <[email protected]>
Date: Thu, 27 Jun 2024 18:54:12 +0900
Subject: [PATCH] change ExecStart argument

Change ExecStart argument for telegraf config directory.
---
Upstream-Status: Inappropriate [webos specific]

scripts/telegraf.service | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/telegraf.service b/scripts/telegraf.service
index ff9860d5c..cde07a412 100644
--- a/scripts/telegraf.service
+++ b/scripts/telegraf.service
@@ -6,7 +6,7 @@ After=network.target
[Service]
EnvironmentFile=-/etc/default/telegraf
User=telegraf
-ExecStart=/usr/bin/telegraf -config /etc/telegraf/telegraf.conf -config-directory /etc/telegraf/telegraf.d $TELEGRAF_OPTS
+ExecStart=/usr/bin/telegraf -config /etc/telegraf/telegraf.conf -config-directory /var/lib/com.webos.service.sdkagent/telegraf.d $TELEGRAF_OPTS
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure
RestartForceExitStatus=SIGPIPE
5 changes: 4 additions & 1 deletion meta-webos/recipes-devtools/telegraf/telegraf_1.21.4.bb
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,10 @@ SRC_URI = "git://github.com/influxdata/telegraf.git;protocol=https;branch=releas
file://0002-Remove-unused-plugins-for-v1.21.4.patch;patchdir=src/${GO_IMPORT} \
file://0003-Apply-inputs.socket_listener-plugin-for-sdkagent.patch;patchdir=src/${GO_IMPORT} \
file://0004-Add-plugins-for-dashboard.patch;patchdir=src/${GO_IMPORT} \
file://0005-Change-telegraf-config-directory.patch;patchdir=src/${GO_IMPORT} \
"

PR = "r4"
PR = "r5"

GO_IMPORT = "import"

Expand Down Expand Up @@ -96,6 +97,8 @@ do_install() {

# /var
#install -d ${D}${localstatedir}/log/telegraf
install -d ${D}${localstatedir}/lib/com.webos.service.sdkagent
install -d ${D}${localstatedir}/lib/com.webos.service.sdkagent/telegraf.d
}

inherit systemd
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ LIC_FILES_CHKSUM = " \
DEPENDS = "glib-2.0 luna-service2 json-c pmloglib libpbnjson"
RDEPENDS:${PN} += "telegraf"

WEBOS_VERSION = "1.0.0-12_09765a8908962147e7f137d3811cb2443ba234d7"
WEBOS_VERSION = "1.0.0-13_803b98116d12139a5075ddca0310cde0f67c216b"
PR = "r1"

inherit systemd
Expand Down

0 comments on commit 40cf609

Please sign in to comment.