aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2014-08-08 21:32:03 -0300
committerSilvio Rhatto <rhatto@riseup.net>2014-08-08 21:32:03 -0300
commitf3a248f94349cd3816286f0bb7b60fd971608cdf (patch)
tree8134bf3e7c941d73906856738d2d5181f803a274
parent7046434831b74f5edbc11eef091d0adc85ac5cb9 (diff)
downloadsmartmonster-f3a248f94349cd3816286f0bb7b60fd971608cdf.tar.gz
smartmonster-f3a248f94349cd3816286f0bb7b60fd971608cdf.tar.bz2
Make it a puppet module
-rw-r--r--Makefile6
-rwxr-xr-xfiles/99_smartmonster_sleep.d.sh (renamed from src/99_smartmonster_sleep.d.sh)0
-rwxr-xr-xfiles/file_system_reporter.sh (renamed from src/file_system_reporter.sh)0
-rwxr-xr-xfiles/update_power_counter.sh (renamed from src/update_power_counter.sh)0
-rw-r--r--manifests/init.pp25
5 files changed, 28 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 619c4e1..d8dabb9 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
install:
- cp src/file_system_reporter.sh $(DESTDIR)/usr/bin/
- cp src/update_power_counter.sh $(DESTDIR)/usr/bin/
- cp src/99_smartmonster_sleep.d.sh $(DESTDIR)/etc/pm/sleep.d/
+ cp files/file_system_reporter.sh $(DESTDIR)/usr/bin/
+ cp files/update_power_counter.sh $(DESTDIR)/usr/bin/
+ cp files/99_smartmonster_sleep.d.sh $(DESTDIR)/etc/pm/sleep.d/
diff --git a/src/99_smartmonster_sleep.d.sh b/files/99_smartmonster_sleep.d.sh
index 2977bdb..2977bdb 100755
--- a/src/99_smartmonster_sleep.d.sh
+++ b/files/99_smartmonster_sleep.d.sh
diff --git a/src/file_system_reporter.sh b/files/file_system_reporter.sh
index e88d70d..e88d70d 100755
--- a/src/file_system_reporter.sh
+++ b/files/file_system_reporter.sh
diff --git a/src/update_power_counter.sh b/files/update_power_counter.sh
index 785dc1e..785dc1e 100755
--- a/src/update_power_counter.sh
+++ b/files/update_power_counter.sh
diff --git a/manifests/init.pp b/manifests/init.pp
new file mode 100644
index 0000000..93166a2
--- /dev/null
+++ b/manifests/init.pp
@@ -0,0 +1,25 @@
+class smartmonster {
+ file { '/usr/local/sbin/file_system_reporter.sh':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => 0755,
+ source => 'puppet:///modules/smartmonster/file_system_reporter.sh',
+ }
+
+ file { '/usr/local/sbin/update_power_counter.sh':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => '0755',
+ source => 'puppet:///modules/smartmonster/update_power_counter.sh',
+ }
+
+ file { '/etc/pm/sleep.d/99_smartmonster_sleep.d.sh':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => '0755',
+ source => 'puppet:///modules/smartmonster/99_smartmonster_sleep.d.sh',
+ }
+}