Skip to content

Commit

Permalink
Add dbus config and systemd config, installation and packaging of kan…
Browse files Browse the repository at this point in the history
…o-memory-monitor
  • Loading branch information
Ealdwulf committed Nov 17, 2016
1 parent dffcc22 commit 9e172b8
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 1 deletion.
17 changes: 17 additions & 0 deletions config/dbus/me.kano.monitor.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@

<!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-Bus Bus Configuration 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">

<busconfig>

<policy context="default">

<!-- Allow kano-boards-daemon to reserve the bus name -->
<allow own="me.kano.monitor"/>

<!-- Allow clients to call methods on interfaces on this bus name -->
<allow send_destination="me.kano.monitor"/>

</policy>

</busconfig>
3 changes: 3 additions & 0 deletions config/sudoers.d/kano-desktop_conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ Cmnd_Alias KILL_DESKTOP_WIDGETS = /usr/bin/pkill kano-settings, \

# allow user to switch to virtual console terminals
%sudo ALL=(root) NOPASSWD: /bin/chvt

# kano-memory-monitor is run as root to allow pid tracking
%sudo ALL=(root) NOPASSWD: kano-memory-monitor
4 changes: 4 additions & 0 deletions debian/install
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ config/gtk-2.0 etc/skel/.config/
config/dconf etc/skel/.config/
config/console usr/share/kano-desktop/config

config/dbus/me.kano.monitor.conf /etc/dbus-1/system.d/

config/sudoers.d/* usr/share/kano-desktop/config/sudoers.d

config/systemd/kano.conf /lib/systemd/system/[email protected]
Expand All @@ -45,3 +47,5 @@ kano-mount-trigger/kano-mount-trigger /usr/bin/
kano-mount-trigger/95-kano-mount-trigger.rules /lib/udev/rules.d/

systemd/* /usr/lib/systemd/user/

kano_monitor /usr/lib/python2.7/dist-packages/
10 changes: 10 additions & 0 deletions systemd/kano-common-monitor.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#
# kano-common-monitor
#

[Unit]
Description=Kano Memory Monitor
IgnoreOnIsolate=true

[Service]
ExecStart=sudo /usr/bin/kano-memory-monitor
2 changes: 1 addition & 1 deletion systemd/kano-common.target
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ Description=Kano Common User Services
IgnoreOnIsolate=true
Requires=kano-common-tracker.service kano-common-notifications.service \
kano-common-speakerleds.service kano-common-boards.service \
kano-common-keyboard.service
kano-common-keyboard.service kano-common-monitor.service

0 comments on commit 9e172b8

Please sign in to comment.