marionette 0.0.7 → 0.0.8

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -5,9 +5,10 @@ Marionette connects a headstartapp server instance (puppet node) to its
5
5
  master and executes puppet runs on demand. Marionette uses fast and lightweight
6
6
  0MQ <http://zeromq.org> messaging system.
7
7
 
8
-
9
-
10
- For more about Headstartapp see <http://headstartapp.com>.
8
+ From version 0.0.8 onward, use puppet agent for puppet runs
9
+ From version 0.0.7 onward, talk replaces send and receive.
10
+ From version 0.0.7 onward, marionette reconnects after n-poll attempts (10 by default).
11
+ From version 0.0.6 onward, marionette polls before receives.
11
12
 
12
13
 
13
14
  Installation
@@ -47,15 +48,14 @@ Ruby:
47
48
 
48
49
  puppet = HeadStartApp::Marionette::Connect.new(:uri=>"192.168.1.1:5555) puppet
49
50
  master = HeadStartApp::Marionette::Connect.new(:uri=>"192.168.1.1:5555").master
50
- message = {:run=>{:system=>true,:facter=>true},:system=>{:command=>"echo 'test @ #{Time.now}' > /tmp/test.out"}}
51
- master.send message
52
- master.receive
51
+ message = {:run=>[:system,:facter,:puppet],:system=>{:command=>"echo 'test @ #{Time.now}' > /tmp/test.out"}}
52
+ master.talk messagee
53
53
 
54
54
  # Results:
55
55
  #
56
56
  # 1) on the pupet, /tmp/test.out contains "test #{Time.now}"
57
- # 2) master.receive returns puppet's facts as a hash.
58
- # 3) Note: this example does not execute a puppet run.
57
+ # 2) returns puppet's facts as a hash.
58
+ # 3) completes a puppet run.
59
59
 
60
60
 
61
61
 
@@ -86,11 +86,7 @@ MISC:
86
86
  To Do
87
87
  ----
88
88
 
89
- 1) Complete implementation for puppet runs.
90
-
91
- 2) Example of executing a run.
92
-
93
- 3) Instructions for setting up SSH Tunnel to secure marionette.
89
+ 1) Instructions for setting up SSH Tunnel to secure marionette.
94
90
 
95
91
 
96
92
 
@@ -39,9 +39,9 @@ module HeadStartApp
39
39
 
40
40
  # Execute a puppet run and/or ad hoc system commands
41
41
  @response = Marshal.load(@response)
42
- puppet_run if @response[:run][:puppet]
43
- system_run if @response[:run][:system]
44
- facter_run if @response[:run][:facter]
42
+ puppet_run if @response[:run].include? :puppet
43
+ system_run if @response[:run].include? :system
44
+ facter_run if @response[:run].include? :facter
45
45
 
46
46
  rescue
47
47
 
@@ -84,9 +84,9 @@ module HeadStartApp
84
84
  def puppet_run
85
85
 
86
86
  if @response[:puppet].nil?
87
- system "puppetd --onetime --no-daemonize"
87
+ system "puppet agent --server master.headstartapp.com --verbose --waitforcert 5 --no-daemonize --onetime --logdest /var/log/puppet.log"
88
88
  else
89
- system "puppetd #{@response[:puppet][:args]}"
89
+ system "puppet #{@response[:puppet][:args]}"
90
90
  end
91
91
 
92
92
  end
@@ -1,5 +1,5 @@
1
1
  module HeadStartApp
2
2
  module Marionette
3
- VERSION = "0.0.7"
3
+ VERSION = "0.0.8"
4
4
  end
5
5
  end
data/marionette.gemspec CHANGED
@@ -8,7 +8,7 @@ Gem::Specification.new do |s|
8
8
  s.platform = Gem::Platform::RUBY
9
9
  s.authors = ["Dan Lee"]
10
10
  s.email = ["dan@headstartapp.com"]
11
- s.homepage = "http://headstartapp.com"
11
+ s.homepage = "https://github.com/headstartapp/marionette"
12
12
  s.summary = %q{0MQ connection between puppet and master.}
13
13
  s.description = %q{Marionette connects a headstartapp server instance (puppet node) to its master and executes puppet runs on demand. Marionette uses fast and lightweight 0MQ <http://zeromq.org> messaging system.}
14
14
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: marionette
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 15
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 7
10
- version: 0.0.7
9
+ - 8
10
+ version: 0.0.8
11
11
  platform: ruby
12
12
  authors:
13
13
  - Dan Lee
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-01-12 00:00:00 -08:00
18
+ date: 2011-01-17 00:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -130,7 +130,7 @@ files:
130
130
  - lib/marionette/version.rb
131
131
  - marionette.gemspec
132
132
  has_rdoc: true
133
- homepage: http://headstartapp.com
133
+ homepage: https://github.com/headstartapp/marionette
134
134
  licenses: []
135
135
 
136
136
  post_install_message: