rump 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/LICENSE +165 -0
- data/README.md +118 -0
- data/Rakefile +14 -0
- data/VERSION +1 -0
- data/bin/rump +19 -0
- data/features/rump.feature +179 -0
- data/features/step_definitions/rump_steps.rb +143 -0
- data/features/support/env.rb +11 -0
- data/features/support/repos/simple/manifests/nodes/.stub +0 -0
- data/features/support/repos/simple/manifests/site.pp +1 -0
- data/features/support/repos/simple/modules/test/manifests/init.pp +5 -0
- data/features/support/repos/simple/var/.stub +0 -0
- data/features/support/repos/simple/var/reports/.stub +0 -0
- data/features/support/repos/simple_26/manifests/nodes/.stub +0 -0
- data/features/support/repos/simple_26/manifests/site.pp +1 -0
- data/features/support/repos/simple_26/modules/test/files/checkout +0 -0
- data/features/support/repos/simple_26/modules/test/manifests/init.pp +5 -0
- data/features/support/repos/simple_26/var/.stub +0 -0
- data/features/support/repos/simple_26/var/reports/.stub +0 -0
- data/lib/generators/git/description +1 -0
- data/lib/generators/git/hooks/pre-commit +29 -0
- data/lib/generators/git/hooks/pre-receive +0 -0
- data/lib/generators/git/info/exclude +6 -0
- data/lib/rump.rb +251 -0
- data/man/rump.1 +328 -0
- data/man/rump.1.html +308 -0
- data/man/rump.1.ronn +214 -0
- metadata +109 -0
data/man/rump.1.ronn
ADDED
@@ -0,0 +1,214 @@
|
|
1
|
+
Rump
|
2
|
+
====
|
3
|
+
|
4
|
+
## NAME ##
|
5
|
+
|
6
|
+
rump - Do Puppet runs locally from a Git checkout
|
7
|
+
|
8
|
+
## SYNOPSIS ##
|
9
|
+
|
10
|
+
* `rump` go [<puppet-options>]
|
11
|
+
* `rump` clone <repository> [directory]
|
12
|
+
* `rump` freeze [<project> <repository> --release=<release>]
|
13
|
+
* `rump` whoami [rfc2822-address]
|
14
|
+
* `rump` init <project>
|
15
|
+
* `rump` scaffold <project>
|
16
|
+
|
17
|
+
## DESCRIPTION ##
|
18
|
+
|
19
|
+
**Rump** helps you run Puppet locally against a Git checkout.
|
20
|
+
|
21
|
+
Rump supports a Puppet workflow where you quickly + iteratively develop your
|
22
|
+
Puppet manifests on a single machine, then push your changes up to a repository
|
23
|
+
to deploy to the rest of your infrastructure.
|
24
|
+
|
25
|
+
This workflow also complements a Capistrano or MCollective-style deployment,
|
26
|
+
where you remotely instruct Rump to check out a copy of the latest manifests
|
27
|
+
and run them.
|
28
|
+
|
29
|
+
Rump also has the ability to freeze Puppet in to the manifests repository,
|
30
|
+
letting you quickly test different versions of Puppet without waiting for
|
31
|
+
packages to appear, and reducing the dependencies on a system to run Puppet
|
32
|
+
down to just Ruby and git.
|
33
|
+
|
34
|
+
## COMMANDS ##
|
35
|
+
|
36
|
+
* `clone`:
|
37
|
+
Clone a git repository of Puppet manifests.
|
38
|
+
|
39
|
+
<repository> is the url of a git repository. Essentially invokes
|
40
|
+
`git clone`. If [directory] is specified, will clone the repository into
|
41
|
+
the specified directory.
|
42
|
+
|
43
|
+
* `freeze`:
|
44
|
+
Freeze an arbitrary git repository into the current git repository as a
|
45
|
+
submodule under `vendor/`.
|
46
|
+
|
47
|
+
With no arguments, `freeze` will freeze in Puppet + Facter, to the latest
|
48
|
+
commit on master. This is especially useful if you want to track the latest
|
49
|
+
development release of Puppet.
|
50
|
+
|
51
|
+
If <project> and <repository> are specified, a git repository is cloned
|
52
|
+
and set up as a submodule under `vendor/`.
|
53
|
+
|
54
|
+
If `--release` is specified, `freeze` will create and switch to a branch
|
55
|
+
matching a particular tag or revision. Use this to lock to a specific
|
56
|
+
version of Puppet.
|
57
|
+
|
58
|
+
Once the repository is frozen in, switch between tagged releases by `cd`ing
|
59
|
+
to the repository under vendor and running `git checkout <tag>`.
|
60
|
+
|
61
|
+
Any repository frozen under `vendor/` will be added to the Puppet load path
|
62
|
+
when using `rump go`.
|
63
|
+
|
64
|
+
* `go`:
|
65
|
+
Do a Puppet run. Assumes the current directory is a repository of Puppet
|
66
|
+
manifests.
|
67
|
+
|
68
|
+
<puppet-options> are any options you can pass to `puppet` on the command
|
69
|
+
line (e.g. `--debug`, `--verbose`, `--tags foobar`).
|
70
|
+
|
71
|
+
* `help`:
|
72
|
+
Display the man page.
|
73
|
+
|
74
|
+
* `init`:
|
75
|
+
Initialise a repo of scaffolded Puppet manifests. Generates scaffolding for
|
76
|
+
a repository of Puppet manifests, and `git init`s the repository.
|
77
|
+
|
78
|
+
* `scaffold`:
|
79
|
+
Generate scaffolding for a repository of Puppet manifests, primed for Rump.
|
80
|
+
|
81
|
+
Called by `init`. You should never have to call this manually.
|
82
|
+
|
83
|
+
* `whoami`:
|
84
|
+
Sets `user.name` and `user.email` using `git config`. Useful if you have
|
85
|
+
multiple users working with the repository from the same UNIX account.
|
86
|
+
|
87
|
+
If no arguments are specified, will output the currently configured name
|
88
|
+
and email.
|
89
|
+
|
90
|
+
If an argument is specified, treat the argument as an RFC2822 formatted
|
91
|
+
email address, e.g. John Doe <john@example.org>. Sets `user.name` and
|
92
|
+
`user.email` with `git config`.
|
93
|
+
|
94
|
+
Modelled on `bzr whoami`.
|
95
|
+
|
96
|
+
## OPTIONS
|
97
|
+
|
98
|
+
* `--help|-h`:
|
99
|
+
Display the man page.
|
100
|
+
|
101
|
+
## RETURN VALUES ##
|
102
|
+
|
103
|
+
* **0**: Command completed successfully.
|
104
|
+
* **1**: Argument error.
|
105
|
+
* **2**: Subcommand error.
|
106
|
+
* **3**: Required frozen submodule doesn't exist.
|
107
|
+
|
108
|
+
## QUIRKS ##
|
109
|
+
|
110
|
+
1. Puppet's fileserver (`source => "puppet:///..."` on File resources) doesn't
|
111
|
+
behave as expected on Puppet < 2.6. If you are using Puppet < 2.6, all files
|
112
|
+
need to be templates.
|
113
|
+
|
114
|
+
## EXAMPLES ##
|
115
|
+
|
116
|
+
Initialise a Rump-ready Puppet repository:
|
117
|
+
|
118
|
+
$ rump init barfoo
|
119
|
+
Initialized empty Git repository in barfoo/.git/
|
120
|
+
|
121
|
+
Clone a git repository of Puppet manifests:
|
122
|
+
|
123
|
+
$ rump clone git@github.com:exampledotorg/manifests.git
|
124
|
+
|
125
|
+
Clone a git repository of Puppet manifests into a specific directory:
|
126
|
+
|
127
|
+
$ rump clone git@github.com:exampledotorg/manifests.git another_clone
|
128
|
+
|
129
|
+
Graft a Rump scaffold onto an existing repository of manifests:
|
130
|
+
|
131
|
+
$ rump scaffold another_clone
|
132
|
+
|
133
|
+
Freeze Puppet and Facter:
|
134
|
+
|
135
|
+
$ rump freeze
|
136
|
+
Cloning into vendor/puppet...
|
137
|
+
remote: Counting objects: 72007, done.
|
138
|
+
remote: Compressing objects: 100% (22120/22120), done.
|
139
|
+
remote: Total 72007 (delta 52640), reused 66470 (delta 48322)
|
140
|
+
Receiving objects: 100% (72007/72007), 12.13 MiB | 253 KiB/s, done.
|
141
|
+
Resolving deltas: 100% (52640/52640), done.
|
142
|
+
Cloning into vendor/facter...
|
143
|
+
remote: Counting objects: 4185, done.
|
144
|
+
remote: Compressing objects: 100% (1930/1930), done.
|
145
|
+
remote: Total 4185 (delta 2202), reused 3973 (delta 2095)
|
146
|
+
Receiving objects: 100% (4185/4185), 840.81 KiB | 174 KiB/s, done.
|
147
|
+
Resolving deltas: 100% (2202/2202), done.
|
148
|
+
Freezing complete.
|
149
|
+
|
150
|
+
Freeze some other repository:
|
151
|
+
|
152
|
+
$ rump freeze moonshine https://github.com/railsmachine/moonshine.git
|
153
|
+
Cloning into vendor/moonshine...
|
154
|
+
remote: Counting objects: 4122, done.
|
155
|
+
remote: Compressing objects: 100% (1976/1976), done.
|
156
|
+
remote: Total 4122 (delta 2190), reused 3730 (delta 1911)
|
157
|
+
Receiving objects: 100% (4122/4122), 543.59 KiB | 58 KiB/s, done.
|
158
|
+
Resolving deltas: 100% (2190/2190), done.
|
159
|
+
Freezing complete.
|
160
|
+
|
161
|
+
Freeze Puppet at a particular version:
|
162
|
+
|
163
|
+
$ rump freeze puppet git://github.com/puppetlabs/puppet.git --release=2.6.2
|
164
|
+
Cloning into /Users/auxesis/foobar/vendor/puppet...
|
165
|
+
remote: Counting objects: 72007, done.
|
166
|
+
remote: Compressing objects: 100% (22120/22120), done.
|
167
|
+
remote: Total 72007 (delta 52640), reused 66470 (delta 48322)
|
168
|
+
Receiving objects: 100% (72007/72007), 12.13 MiB | 238 KiB/s, done.
|
169
|
+
Resolving deltas: 100% (52640/52640), done.
|
170
|
+
Switched to a new branch '2.6.2'
|
171
|
+
Freezing complete.
|
172
|
+
|
173
|
+
Do a Puppet run:
|
174
|
+
|
175
|
+
$ rump go
|
176
|
+
You should probably be root when running this! Proceeding anyway...
|
177
|
+
Using frozen Puppet from vendor/puppet.
|
178
|
+
notice: Finished catalog run in 0.01 seconds
|
179
|
+
|
180
|
+
Do a Puppet run, and pass in arguments to Puppet:
|
181
|
+
|
182
|
+
$ rump go --noop --debug
|
183
|
+
You should probably be root when running this! Proceeding anyway...
|
184
|
+
Using frozen Puppet from vendor/puppet.
|
185
|
+
ruby -I vendor/facter/lib -I vendor/puppet/lib vendor/puppet/bin/puppet
|
186
|
+
--modulepath modules --confdir etc --vardir var manifests/site.pp --noop --debug
|
187
|
+
debug: Creating default schedules
|
188
|
+
debug: Failed to load library 'selinux' for feature 'selinux'
|
189
|
+
debug: Puppet::Type::File::ProviderMicrosoft_windows: feature microsoft_windows is missing
|
190
|
+
debug: Failed to load library 'ldap' for feature 'ldap'
|
191
|
+
debug: Failed to load library 'shadow' for feature 'libshadow'
|
192
|
+
...
|
193
|
+
|
194
|
+
Find out who the currently configured git user is:
|
195
|
+
|
196
|
+
$ rump whoami
|
197
|
+
Jane Doe <jane@example.org>
|
198
|
+
|
199
|
+
Set the git user:
|
200
|
+
|
201
|
+
$ rump whoami 'John Doe <john@example.org>'
|
202
|
+
|
203
|
+
|
204
|
+
## AUTHOR ##
|
205
|
+
|
206
|
+
Lindsay Holmwood <lindsay@holmwood.id.au>
|
207
|
+
|
208
|
+
## COPYRIGHT ##
|
209
|
+
|
210
|
+
Copyright Rails Machine LLC 2010-2011, released under the LGPL
|
211
|
+
|
212
|
+
## SEE ALSO ##
|
213
|
+
|
214
|
+
puppet(8)
|
metadata
ADDED
@@ -0,0 +1,109 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: rump
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 21
|
5
|
+
prerelease:
|
6
|
+
segments:
|
7
|
+
- 0
|
8
|
+
- 2
|
9
|
+
- 1
|
10
|
+
version: 0.2.1
|
11
|
+
platform: ruby
|
12
|
+
authors:
|
13
|
+
- Lindsay Holmwood
|
14
|
+
autorequire:
|
15
|
+
bindir: bin
|
16
|
+
cert_chain: []
|
17
|
+
|
18
|
+
date: 2011-03-03 00:00:00 -05:00
|
19
|
+
default_executable: rump
|
20
|
+
dependencies:
|
21
|
+
- !ruby/object:Gem::Dependency
|
22
|
+
name: thor
|
23
|
+
prerelease: false
|
24
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - "="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
hash: 35
|
30
|
+
segments:
|
31
|
+
- 0
|
32
|
+
- 13
|
33
|
+
- 4
|
34
|
+
version: 0.13.4
|
35
|
+
type: :runtime
|
36
|
+
version_requirements: *id001
|
37
|
+
description: Rump helps you run Puppet locally against a Git checkout. This is great for locally iterating your Puppet manifests very quickly, then pushng them up to a repository somewhere else to share the changes.
|
38
|
+
email: ops@railsmachine.com
|
39
|
+
executables:
|
40
|
+
- rump
|
41
|
+
extensions: []
|
42
|
+
|
43
|
+
extra_rdoc_files:
|
44
|
+
- LICENSE
|
45
|
+
- README.md
|
46
|
+
files:
|
47
|
+
- LICENSE
|
48
|
+
- README.md
|
49
|
+
- Rakefile
|
50
|
+
- VERSION
|
51
|
+
- bin/rump
|
52
|
+
- features/rump.feature
|
53
|
+
- features/step_definitions/rump_steps.rb
|
54
|
+
- features/support/env.rb
|
55
|
+
- features/support/repos/simple/manifests/nodes/.stub
|
56
|
+
- features/support/repos/simple/manifests/site.pp
|
57
|
+
- features/support/repos/simple/modules/test/manifests/init.pp
|
58
|
+
- features/support/repos/simple/var/.stub
|
59
|
+
- features/support/repos/simple/var/reports/.stub
|
60
|
+
- features/support/repos/simple_26/manifests/nodes/.stub
|
61
|
+
- features/support/repos/simple_26/manifests/site.pp
|
62
|
+
- features/support/repos/simple_26/modules/test/files/checkout
|
63
|
+
- features/support/repos/simple_26/modules/test/manifests/init.pp
|
64
|
+
- features/support/repos/simple_26/var/.stub
|
65
|
+
- features/support/repos/simple_26/var/reports/.stub
|
66
|
+
- lib/generators/git/description
|
67
|
+
- lib/generators/git/hooks/pre-commit
|
68
|
+
- lib/generators/git/hooks/pre-receive
|
69
|
+
- lib/generators/git/info/exclude
|
70
|
+
- lib/rump.rb
|
71
|
+
- man/rump.1
|
72
|
+
- man/rump.1.html
|
73
|
+
- man/rump.1.ronn
|
74
|
+
has_rdoc: true
|
75
|
+
homepage: http://github.com/railsmachine/rump
|
76
|
+
licenses: []
|
77
|
+
|
78
|
+
post_install_message:
|
79
|
+
rdoc_options: []
|
80
|
+
|
81
|
+
require_paths:
|
82
|
+
- lib
|
83
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
84
|
+
none: false
|
85
|
+
requirements:
|
86
|
+
- - ">="
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
hash: 3
|
89
|
+
segments:
|
90
|
+
- 0
|
91
|
+
version: "0"
|
92
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
93
|
+
none: false
|
94
|
+
requirements:
|
95
|
+
- - ">="
|
96
|
+
- !ruby/object:Gem::Version
|
97
|
+
hash: 3
|
98
|
+
segments:
|
99
|
+
- 0
|
100
|
+
version: "0"
|
101
|
+
requirements: []
|
102
|
+
|
103
|
+
rubyforge_project:
|
104
|
+
rubygems_version: 1.5.2
|
105
|
+
signing_key:
|
106
|
+
specification_version: 3
|
107
|
+
summary: Rump helps you run Puppet locally against a Git checkout.
|
108
|
+
test_files: []
|
109
|
+
|