aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2011-12-23 21:42:53 -0200
committerSilvio Rhatto <rhatto@riseup.net>2011-12-23 21:42:53 -0200
commita0139760cc478d3ff81aa9581245415097942d39 (patch)
tree969999ae929d7654286d6bca8f6e795efbf2b2f0
parent9d279e9dd9b86be0c3cbf577064fc94f3d775c1f (diff)
downloadpuppet-nodo-a0139760cc478d3ff81aa9581245415097942d39.tar.gz
puppet-nodo-a0139760cc478d3ff81aa9581245415097942d39.tar.bz2
Adding more classes for utilities
-rw-r--r--manifests/init.pp11
-rw-r--r--manifests/nodo.pp4
-rw-r--r--manifests/subsystems/utils/debian.pp158
-rw-r--r--manifests/subsystems/utils/development.pp10
-rw-r--r--manifests/subsystems/utils/interface.pp8
-rw-r--r--manifests/subsystems/utils/java.pp14
-rw-r--r--manifests/subsystems/utils/laptop.pp10
-rw-r--r--manifests/subsystems/utils/multimedia.pp23
-rw-r--r--manifests/subsystems/utils/network.pp58
-rw-r--r--manifests/subsystems/utils/office.pp11
-rw-r--r--manifests/subsystems/utils/personal.pp11
-rw-r--r--manifests/subsystems/utils/ruby.pp42
-rw-r--r--manifests/subsystems/utils/security.pp14
13 files changed, 218 insertions, 156 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index e1005cb..fd74087 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -72,15 +72,22 @@ import "subsystems/domain.pp"
import "subsystems/utils.pp"
import "subsystems/utils/debian.pp"
import "subsystems/utils/desktop.pp"
+import "subsystems/utils/development.pp"
+import "subsystems/utils/dns.pp"
import "subsystems/utils/firmware.pp"
+import "subsystems/utils/interface.pp"
+import "subsystems/utils/java.pp"
import "subsystems/utils/laptop.pp"
import "subsystems/utils/multimedia.pp"
+import "subsystems/utils/network.pp"
+import "subsystems/utils/office.pp"
import "subsystems/utils/personal.pp"
import "subsystems/utils/physical.pp"
+import "subsystems/utils/plug.pp"
+import "subsystems/utils/ruby.pp"
+import "subsystems/utils/security.pp"
import "subsystems/utils/storage.pp"
import "subsystems/utils/web.pp"
-import "subsystems/utils/plug.pp"
-import "subsystems/utils/dns.pp"
import "subsystems/firewall.pp"
import "subsystems/firewall/printer.pp"
import "subsystems/firewall/router.pp"
diff --git a/manifests/nodo.pp b/manifests/nodo.pp
index ce7a0e0..1904ece 100644
--- a/manifests/nodo.pp
+++ b/manifests/nodo.pp
@@ -51,6 +51,10 @@ class nodo {
default => absent,
}
}
+
+ package { 'apt-transport-https':
+ ensure => present,
+ }
}
# Default SSH configuration
diff --git a/manifests/subsystems/utils/debian.pp b/manifests/subsystems/utils/debian.pp
index 727e5c6..1401aea 100644
--- a/manifests/subsystems/utils/debian.pp
+++ b/manifests/subsystems/utils/debian.pp
@@ -1,167 +1,19 @@
class utils::personal::debian {
# System
- package { [ 'libpam-mount', 'ecryptfs-utils', 'openjdk-6-jre', 'gawk',
- 'sun-java6-jre', 'laptop-detect', 'syslinux' ]:
+ package { [ 'libpam-mount', 'ecryptfs-utils', 'gawk',
+ 'laptop-detect', 'syslinux' ]:
ensure => installed,
}
- # Multimedia
- package { [ 'alsa-tools-gui', 'mp3blaster', 'alsa-utils', 'netpbm',
- 'gqview', 'mpg123', 'audacious', 'qjackctl',
- 'gimp', 'xine-ui', 'amarok', 'wodim',
- 'genisoimage', 'dvd+rw-tools', 'inkscape', 'jhead',
- 'easytag', 'flashplugin-nonfree', 'vlc', 'audacity',
- 'opencubicplayer', 'moc', 'cmus', 'orpheus',
- 'cbrpager', 'llgal', 'darksnow', 'mplayer' ]:
- ensure => installed,
- }
-
- # Interface
- package { [ 'awesome', 'eterm', 'fluxbox', 'gdm', 'conky',
- 'xterm', 'bash-completion', 'xfonts-terminus', 'xscreensaver', 'rxvt-unicode',
- 'mc', 'gtk-theme-switch', 'gtk-smooth-themes', 'rxvt' ]:
- ensure => installed,
- }
-
- # Office
- package { [ 'wyrd', 'vim-gtk', 'gobby',
- 'sc', 'antiword', 'broffice.org',
- 'kalarm', 'texlive-latex-base', 'texlive-latex-recommended',
- 'texlive-latex-extra', 'pandoc', 'gnumeric',
- 'cups-client', 'hplip', 'cups-bsd',
- 'gnucash', 'worklog' ]:
- ensure => installed,
- }
-
- # Network
- package { [ 'mutt', 'irssi', 'offlineimap', 'epiphany-browser',
- 'newsbeuter', 'bitlbee', 'nicotine', 'silc',
- 'irssi-plugin-silc', 'bogofilter', 'fetchmail', 'procmail',
- 'msmtp', 'mairix', 'konqueror', 'bittorrent',
- 'irssi-scripts', 'links', 'twinkle', 'bittornado',
- 'rtorrent', 'iceweasel', 'irssi-plugin-otr', 'transmission',
- 'openvpn', 'amule', 'pssh', 'pidgin',
- 'pidgin-encryption', 'pidgin-openpgp', 'pidgin-otr', 'pidgin-privacy-please',
- 'pidgin-plugin-pack', 'sslscan' ]:
- ensure => installed,
- }
-
- # Security
- package { [ 'apg', 'gnupg-agent', 'makepasswd', 'pwgen', 'fpm2', 'encfs',
- 'signing-party', 'libnss3-tools' ]:
- ensure => installed,
- }
-
- # Development
- package { [ 'debhelper', 'gitk', 'git-gui', 'subversion', 'python-stdeb',
- 'fakeroot', 'dupload', 'autotools-dev', 'dh-make', 'doxygen',
- 'tig', 'mercurial', 'exuberant-ctags', 'reportbug', 'debian-keyring',
- 'devscripts', 'pbuilder', 'build-essential', 'pnopaste-cli', 'agave',
- 'cdbs', 'dh-buildinfo', 'quilt' ]:
- ensure => installed,
- }
-
- # Other
+ # Misc
package { [ 'fortunes-br', 'unrar', 'recode', 'figlet', 'p7zip-full', 'unison', 'funcoeszz' ]:
ensure => installed,
}
# Custom: might not be available in the official repositories
- package { [ 'kedpm', 'torchat' ]:
- ensure => installed,
- }
-
- # Lenny only
- package { [ 'mozilla-firefox-adblock' ]:
- ensure => $lsbdistcodename ? {
- 'lenny' => present,
- default => absent,
- },
- }
-
- # Squeeze (or newer) packages
- if $lsbdistcodename != 'lenny' {
- package { [ 'xul-ext-monkeysphere', 'chromium-browser', 'libical-parser-perl',
- 'maildir-utils', 'icedtea6-plugin', ]:
- ensure => installed,
- }
-
- # See http://tails.boum.org/bugs/FireGPG_may_be_unsafe/
- package { 'xul-ext-firegpg':
- ensure => absent,
- }
- }
-
- # Gem packages
- package { 'capistrano':
- ensure => installed,
- provider => gem,
- require => Package['rubygems'],
- }
-
- # Gem packages
- package { 'slideshow':
- ensure => installed,
- provider => gem,
- require => Package['rubygems'],
- }
-
- if !defined(Package['ruby']) {
- package { 'ruby':
+ if $nodo_use_custom_packages == true {
+ package { [ 'kedpm', 'torchat' ]:
ensure => installed,
}
}
-
- if !defined(Package['rubygems']) {
- package { 'rubygems':
- ensure => installed,
- require => Package['ruby'],
- }
- }
-
- if !defined(Package['ruby-dev']) {
- package { 'ruby-dev':
- ensure => installed,
- require => Package['ruby'],
- }
- }
-
- if !defined(Package['libgpgme-ruby1.8']) {
- package { 'libgpgme-ruby1.8':
- ensure => installed,
- require => Package['ruby'],
- }
- }
-
- # Flash alternative
- file { "/etc/alternatives/flash-mozilla.so":
- ensure => "/usr/lib/flashplugin-nonfree/libflashplayer.so",
- owner => root,
- group => root,
- require => Package['flashplugin-nonfree'],
- }
-
- # Browser alternative
- file { "/etc/alternatives/x-www-browser":
- ensure => "/usr/bin/iceweasel",
- owner => root,
- group => root,
- require => Package['iceweasel'],
- }
-
- # Browser alternative: manpage
- file { "/etc/alternatives/x-www-browser.1.gz":
- ensure => "/usr/share/man/man1/iceweasel.1.gz",
- owner => root,
- group => root,
- require => Package['iceweasel'],
- }
-
- # Java alternative
- file { "/etc/alternatives/java":
- ensure => "/usr/lib/jvm/java-6-sun/jre/bin/java",
- owner => root,
- group => root,
- require => Package['sun-java6-jre'],
- }
}
diff --git a/manifests/subsystems/utils/development.pp b/manifests/subsystems/utils/development.pp
new file mode 100644
index 0000000..a933910
--- /dev/null
+++ b/manifests/subsystems/utils/development.pp
@@ -0,0 +1,10 @@
+class utils::development {
+ # Development
+ package { [ 'debhelper', 'gitk', 'git-gui', 'subversion', 'python-stdeb',
+ 'fakeroot', 'dupload', 'autotools-dev', 'dh-make', 'doxygen',
+ 'tig', 'mercurial', 'exuberant-ctags', 'reportbug', 'debian-keyring',
+ 'devscripts', 'pbuilder', 'build-essential', 'pnopaste-cli', 'agave',
+ 'cdbs', 'dh-buildinfo', 'quilt' ]:
+ ensure => installed,
+ }
+}
diff --git a/manifests/subsystems/utils/interface.pp b/manifests/subsystems/utils/interface.pp
new file mode 100644
index 0000000..938b87f
--- /dev/null
+++ b/manifests/subsystems/utils/interface.pp
@@ -0,0 +1,8 @@
+class utils::interface {
+ # Interface
+ package { [ 'awesome', 'eterm', 'fluxbox', 'gdm', 'conky',
+ 'xterm', 'bash-completion', 'xfonts-terminus', 'xscreensaver', 'rxvt-unicode',
+ 'mc', 'gtk-theme-switch', 'gtk-smooth-themes', 'rxvt' ]:
+ ensure => installed,
+ }
+}
diff --git a/manifests/subsystems/utils/java.pp b/manifests/subsystems/utils/java.pp
new file mode 100644
index 0000000..903bc73
--- /dev/null
+++ b/manifests/subsystems/utils/java.pp
@@ -0,0 +1,14 @@
+class utils::java {
+ # Java
+ package { [ 'sun-java6-jre', 'openjdk-6-jre' ]:
+ ensure => installed,
+ }
+
+ # Java alternative
+ file { "/etc/alternatives/java":
+ ensure => "/usr/lib/jvm/java-6-sun/jre/bin/java",
+ owner => root,
+ group => root,
+ require => Package['sun-java6-jre'],
+ }
+}
diff --git a/manifests/subsystems/utils/laptop.pp b/manifests/subsystems/utils/laptop.pp
index 3c39cec..f3be2bc 100644
--- a/manifests/subsystems/utils/laptop.pp
+++ b/manifests/subsystems/utils/laptop.pp
@@ -1,5 +1,15 @@
# Common utilities for laptop
class utils::laptop {
+ case $operatingsystem {
+ debian: {
+ include utils::laptop::debian
+ }
+ default: { }
+ }
+}
+
+# Common utilities for debian laptops
+class utils::laptop::debian {
package { [ 'cpufrequtils', 'module-assistant', 'wireless-tools',
'wpasupplicant', 'ekiga', 'gnome',
'revelation', 'wicd', 'wicd-curses',
diff --git a/manifests/subsystems/utils/multimedia.pp b/manifests/subsystems/utils/multimedia.pp
index c4322b3..91a880d 100644
--- a/manifests/subsystems/utils/multimedia.pp
+++ b/manifests/subsystems/utils/multimedia.pp
@@ -1,5 +1,5 @@
# Multimedia utilities
-class utils::multimedia {
+class utils::multimedia::studio {
package { [ 'ardour', 'hydrogen', ]:
ensure => $lsbdistcodename ? {
'lenny' => absent,
@@ -7,3 +7,24 @@ class utils::multimedia {
}
}
}
+
+class utils::multimedia {
+ # Multimedia
+ package { [ 'alsa-tools-gui', 'mp3blaster', 'alsa-utils', 'netpbm',
+ 'gqview', 'mpg123', 'audacious', 'qjackctl',
+ 'gimp', 'xine-ui', 'amarok', 'wodim',
+ 'genisoimage', 'dvd+rw-tools', 'inkscape', 'jhead',
+ 'easytag', 'flashplugin-nonfree', 'vlc', 'audacity',
+ 'opencubicplayer', 'moc', 'cmus', 'orpheus',
+ 'cbrpager', 'llgal', 'darksnow', 'mplayer' ]:
+ ensure => installed,
+ }
+
+ # Flash alternative
+ file { "/etc/alternatives/flash-mozilla.so":
+ ensure => "/usr/lib/flashplugin-nonfree/libflashplayer.so",
+ owner => root,
+ group => root,
+ require => Package['flashplugin-nonfree'],
+ }
+}
diff --git a/manifests/subsystems/utils/network.pp b/manifests/subsystems/utils/network.pp
new file mode 100644
index 0000000..5671f95
--- /dev/null
+++ b/manifests/subsystems/utils/network.pp
@@ -0,0 +1,58 @@
+class utils::network {
+ # Network
+ package { [ 'mutt', 'irssi', 'offlineimap', 'epiphany-browser',
+ 'newsbeuter', 'bitlbee', 'nicotine', 'silc',
+ 'irssi-plugin-silc', 'bogofilter', 'fetchmail', 'procmail',
+ 'msmtp', 'mairix', 'konqueror', 'bittorrent',
+ 'irssi-scripts', 'links', 'twinkle', 'bittornado',
+ 'rtorrent', 'iceweasel', 'irssi-plugin-otr', 'transmission',
+ 'openvpn', 'amule', 'pssh', 'pidgin',
+ 'pidgin-encryption', 'pidgin-openpgp', 'pidgin-otr', 'pidgin-privacy-please',
+ 'pidgin-plugin-pack', 'sslscan' ]:
+ ensure => installed,
+ }
+
+ # Custom: might not be available in the official repositories
+ if $nodo_use_custom_packages == true {
+ package { [ 'torchat' ]:
+ ensure => installed,
+ }
+ }
+
+ # Squeeze (or newer) packages
+ if $lsbdistcodename != 'lenny' {
+ package { [ 'xul-ext-monkeysphere', 'chromium-browser', 'libical-parser-perl',
+ 'maildir-utils', 'icedtea6-plugin', ]:
+ ensure => installed,
+ }
+
+ # See http://tails.boum.org/bugs/FireGPG_may_be_unsafe/
+ package { 'xul-ext-firegpg':
+ ensure => absent,
+ }
+ }
+
+ # Lenny only
+ package { [ 'mozilla-firefox-adblock' ]:
+ ensure => $lsbdistcodename ? {
+ 'lenny' => present,
+ default => absent,
+ },
+ }
+
+ # Browser alternative
+ file { "/etc/alternatives/x-www-browser":
+ ensure => "/usr/bin/iceweasel",
+ owner => root,
+ group => root,
+ require => Package['iceweasel'],
+ }
+
+ # Browser alternative: manpage
+ file { "/etc/alternatives/x-www-browser.1.gz":
+ ensure => "/usr/share/man/man1/iceweasel.1.gz",
+ owner => root,
+ group => root,
+ require => Package['iceweasel'],
+ }
+}
diff --git a/manifests/subsystems/utils/office.pp b/manifests/subsystems/utils/office.pp
new file mode 100644
index 0000000..ba87d17
--- /dev/null
+++ b/manifests/subsystems/utils/office.pp
@@ -0,0 +1,11 @@
+class utils::office {
+ # Office
+ package { [ 'wyrd', 'vim-gtk', 'gobby',
+ 'sc', 'antiword', 'broffice.org',
+ 'kalarm', 'texlive-latex-base', 'texlive-latex-recommended',
+ 'texlive-latex-extra', 'pandoc', 'gnumeric',
+ 'cups-client', 'hplip', 'cups-bsd',
+ 'gnucash', 'worklog' ]:
+ ensure => installed,
+ }
+}
diff --git a/manifests/subsystems/utils/personal.pp b/manifests/subsystems/utils/personal.pp
index 398b12c..a63548f 100644
--- a/manifests/subsystems/utils/personal.pp
+++ b/manifests/subsystems/utils/personal.pp
@@ -7,3 +7,14 @@ class utils::personal {
default: { }
}
}
+
+class utils::personal::bundle {
+ include utils::office
+ include utils::interface
+ include utils::network
+ include utils::development
+ include utils::security
+ include utils::multimedia
+ include utils::ruby
+ include utils::java
+}
diff --git a/manifests/subsystems/utils/ruby.pp b/manifests/subsystems/utils/ruby.pp
new file mode 100644
index 0000000..0835632
--- /dev/null
+++ b/manifests/subsystems/utils/ruby.pp
@@ -0,0 +1,42 @@
+class utils::ruby {
+ # Gem packages
+ package { 'capistrano':
+ ensure => installed,
+ provider => gem,
+ require => Package['rubygems'],
+ }
+
+ # Gem packages
+ package { 'slideshow':
+ ensure => installed,
+ provider => gem,
+ require => Package['rubygems'],
+ }
+
+ if !defined(Package['ruby']) {
+ package { 'ruby':
+ ensure => installed,
+ }
+ }
+
+ if !defined(Package['rubygems']) {
+ package { 'rubygems':
+ ensure => installed,
+ require => Package['ruby'],
+ }
+ }
+
+ if !defined(Package['ruby-dev']) {
+ package { 'ruby-dev':
+ ensure => installed,
+ require => Package['ruby'],
+ }
+ }
+
+ if !defined(Package['libgpgme-ruby1.8']) {
+ package { 'libgpgme-ruby1.8':
+ ensure => installed,
+ require => Package['ruby'],
+ }
+ }
+}
diff --git a/manifests/subsystems/utils/security.pp b/manifests/subsystems/utils/security.pp
new file mode 100644
index 0000000..1498e94
--- /dev/null
+++ b/manifests/subsystems/utils/security.pp
@@ -0,0 +1,14 @@
+class utils::security {
+ # Security
+ package { [ 'apg', 'gnupg-agent', 'makepasswd', 'pwgen', 'fpm2', 'encfs',
+ 'signing-party', 'libnss3-tools' ]:
+ ensure => installed,
+ }
+
+ # Custom: might not be available in the official repositories
+ if $nodo_use_custom_packages == true {
+ package { [ 'kedpm' ]:
+ ensure => installed,
+ }
+ }
+}