marionetta 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +19 -16
- data/lib/marionetta/manipulators.rb +2 -2
- data/lib/marionetta.rb +1 -1
- data/spec/marionetta_rake_helper_spec.rb +1 -0
- metadata +1 -1
data/README.md
CHANGED
@@ -70,51 +70,54 @@ end
|
|
70
70
|
servers.manipulate_each_server(:puppet, :update)
|
71
71
|
```
|
72
72
|
|
73
|
-
## Using
|
74
|
-
|
75
|
-
Marionetta provides an easy mechanism to generate rake tasks
|
76
|
-
for each of your groups.
|
73
|
+
## Using the debloyer
|
77
74
|
|
78
|
-
|
75
|
+
Also included is a .deb deploying manipulator. You can use
|
76
|
+
this to deploy your application over SSH as a .deb.
|
79
77
|
|
80
78
|
``` ruby
|
81
79
|
require 'marionetta/group'
|
82
|
-
require 'marionetta/rake_helper'
|
83
80
|
|
84
81
|
staging = Marionetta::Group.new(:staging)
|
85
82
|
|
86
83
|
staging.add_server do |s|
|
87
84
|
s[:hostname] = 'staging.example.com'
|
88
|
-
s[:
|
85
|
+
s[:debloyer][:from] = '/my-app'
|
86
|
+
s[:debloyer][:to] = '/home/staging/www'
|
89
87
|
end
|
90
88
|
|
91
|
-
|
89
|
+
staging.manipulate_each_server(:debloyer, :deploy)
|
92
90
|
```
|
93
91
|
|
94
|
-
|
95
|
-
will now be available in your Rakefile.
|
96
|
-
|
97
|
-
**Groups must have names if you want to generate rake tasks.**
|
92
|
+
## Using Marionetta in your Rakefile
|
98
93
|
|
99
|
-
|
94
|
+
Marionetta provides an easy mechanism to generate rake tasks
|
95
|
+
for each of your groups.
|
100
96
|
|
101
|
-
|
102
|
-
this to deploy your application over SSH as a .deb.
|
97
|
+
In your Rakefile you can do something like so:
|
103
98
|
|
104
99
|
``` ruby
|
105
100
|
require 'marionetta/group'
|
101
|
+
require 'marionetta/rake_helper'
|
106
102
|
|
107
103
|
staging = Marionetta::Group.new(:staging)
|
108
104
|
|
109
105
|
staging.add_server do |s|
|
110
106
|
s[:hostname] = 'staging.example.com'
|
107
|
+
s[:puppet][:manifest] = 'puppet/manifest.pp'
|
111
108
|
s[:debloyer][:from] = '/my-app'
|
112
109
|
s[:debloyer][:to] = '/home/staging/www'
|
113
110
|
end
|
114
111
|
|
115
|
-
|
112
|
+
Marionetta::RakeHelper.new(staging).install_group_tasks
|
116
113
|
```
|
117
114
|
|
115
|
+
The tasks `staging:puppet:install`, `staging:puppet:update`
|
116
|
+
`staging:debloyer:deploy` will now be available in your
|
117
|
+
Rakefile.
|
118
|
+
|
119
|
+
**Groups must have names if you want to generate rake tasks.**
|
120
|
+
|
118
121
|
## Author
|
119
122
|
|
120
123
|
Luke Morton a.k.a. DrPheltRight
|
data/lib/marionetta.rb
CHANGED