diff options
author | Sergey Solomin <sergey.solomin@us.ibm.com> | 2016-08-15 22:21:08 +0300 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2016-08-17 17:28:43 +0300 |
commit | 028af1daadfe071e6741364301fdfa91bdd87db9 (patch) | |
tree | f3d072f1dfee4e262c581ffaec35b6386c93c024 /meta-phosphor/common | |
parent | 34239211d138302b59858b22880c2bf39fd0890f (diff) | |
download | openbmc-028af1daadfe071e6741364301fdfa91bdd87db9.tar.xz |
phosphor-event: Convert options to config file
The systemd unit file for phosphor-event currently hard
codes the maximum buffer size. Convert this to a systemd
EnvironmentFile so that it can more easily be replaced or
changed on individual systems.
Resolves openbmc/openbmc#216.
Change-Id: I17d471a872248190ca6eace41bc2ea41eb60bee6
Signed-off-by: Sergey Solomin <sergey.solomin@us.ibm.com>
Diffstat (limited to 'meta-phosphor/common')
3 files changed, 9 insertions, 1 deletions
diff --git a/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/eventd.conf b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/eventd.conf new file mode 100644 index 0000000000..b50dfbcea0 --- /dev/null +++ b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/eventd.conf @@ -0,0 +1,4 @@ +LOG_SIZE_LIMIT="197376" +LOG_COUNT_LIMIT="128" + +OPTIONS="-s ${LOG_SIZE_LIMIT} -t ${LOG_COUNT_LIMIT}" diff --git a/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/obmc-phosphor-event.service b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/obmc-phosphor-event.service index 065cc555b7..a93fce0546 100644 --- a/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/obmc-phosphor-event.service +++ b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/files/obmc-phosphor-event.service @@ -2,8 +2,9 @@ Description=Phosphor OpenBMC event management daemon [Service] +EnvironmentFile=-/etc/default/eventd/eventd.conf Restart=always -ExecStart=/usr/sbin/obmc-phosphor-eventd -s 200000 -t 128 +ExecStart=/usr/sbin/obmc-phosphor-eventd $OPTIONS [Install] WantedBy=multi-user.target diff --git a/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/obmc-phosphor-event.bb b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/obmc-phosphor-event.bb index eeb4a79e53..2ab7ce5f03 100644 --- a/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/obmc-phosphor-event.bb +++ b/meta-phosphor/common/recipes-phosphor/obmc-phosphor-event/obmc-phosphor-event.bb @@ -12,6 +12,7 @@ inherit obmc-phosphor-c-daemon TARGET_CPPFLAGS += "-std=c++11 -fpic" SRC_URI += "git://github.com/openbmc/phosphor-event" +SRC_URI += "file://eventd.conf" SRCREV = "4dad23916e69d55d692eca7389d67eb023c5ca66" @@ -26,4 +27,6 @@ do_install() { install -d ${D}/var/lib/obmc/events/ install -m 0755 -d ${D}${sbindir} install -m 0755 ${S}/${INSTALL_NAME} ${D}/${sbindir}/obmc-phosphor-eventd + install -m 0755 -d ${D}${sysconfdir}/default/eventd + install -m 0644 ${WORKDIR}/eventd.conf ${D}${sysconfdir}/default/eventd/eventd.conf } |