diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2013-04-12 17:12:53 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2013-04-12 17:12:53 -0300 |
commit | e7db0ea316fb9bf2c7ae5792a447697a561d839d (patch) | |
tree | 0311a4a205e4908d29f5d1536903efdba0454fc3 /manifests | |
download | puppet-onion-e7db0ea316fb9bf2c7ae5792a447697a561d839d.tar.gz puppet-onion-e7db0ea316fb9bf2c7ae5792a447697a561d839d.tar.bz2 |
Initial import
Diffstat (limited to 'manifests')
-rw-r--r-- | manifests/freenode.pp | 11 | ||||
-rw-r--r-- | manifests/full.pp | 12 | ||||
-rw-r--r-- | manifests/init.pp | 13 | ||||
-rw-r--r-- | manifests/socks.pp | 7 | ||||
-rw-r--r-- | manifests/ssh.pp | 7 |
5 files changed, 50 insertions, 0 deletions
diff --git a/manifests/freenode.pp b/manifests/freenode.pp new file mode 100644 index 0000000..0e1e462 --- /dev/null +++ b/manifests/freenode.pp @@ -0,0 +1,11 @@ +class onion::freenode inherits onion::socks { + # Freenode via Tor + # http://freenode.net/irc_servers.shtml + # http://pthree.org/2010/01/31/freenode-ssl-and-sasl-authentication-with-irssi/ + # http://freenode.net/sasl/sasl-irssi.shtml + # https://wiki.archlinux.org/index.php/Tor + tor::daemon::map_address { 'freenode': + address => '10.40.40.40', + newaddress => 'p4fsi4ockecnea7l.onion', + } +} diff --git a/manifests/full.pp b/manifests/full.pp new file mode 100644 index 0000000..4657ea4 --- /dev/null +++ b/manifests/full.pp @@ -0,0 +1,12 @@ +class onion::full inherits onion::freenode { + include onion::ssh + + # Currently tor management just works for debian + case $::operatingsystem { + debian: { + include tor::polipo + } + default: { } + } + +} diff --git a/manifests/init.pp b/manifests/init.pp new file mode 100644 index 0000000..14a4e27 --- /dev/null +++ b/manifests/init.pp @@ -0,0 +1,13 @@ +class onion { + class { 'tor::daemon': } + + # It's important to use a subdir from the tor datadir + # to ease backup/restore procedures as we don't mix + # hidden service data with other tor files. + file { "${tor::daemon::data_dir}/hidden": + ensure => directory, + owner => 'debian-tor', + group => 'debian-tor', + mode => 0700, + } +} diff --git a/manifests/socks.pp b/manifests/socks.pp new file mode 100644 index 0000000..88ecf47 --- /dev/null +++ b/manifests/socks.pp @@ -0,0 +1,7 @@ +class onion::socks inherits onion { + # Default tor daemon configuration + tor::daemon::socks { 'socks': + port => 9050, + listen_addresses => [ '127.0.0.1' ], + } +} diff --git a/manifests/ssh.pp b/manifests/ssh.pp new file mode 100644 index 0000000..b39e11f --- /dev/null +++ b/manifests/ssh.pp @@ -0,0 +1,7 @@ +class onion::ssh { + tor::daemon::hidden_service { 'ssh': + ports => [ "22 127.0.0.1:22" ], + data_dir => "${tor::daemon::data_dir}/hidden", + ensure => present, + } +} |