|
1 |
|
2 = symphony-ssh |
|
3 |
|
4 == Description |
|
5 |
|
6 This is a small collection of base classes used for interacting with |
|
7 remote machines over ssh. With them, you can use AMQP (via Symphony) to |
|
8 run batch commands, execute templates as scripts, and perform any |
|
9 batch/remoting stuff you can think of without the need of a separate |
|
10 client agent. |
|
11 |
|
12 These classes assume you have a user that can connect and login to |
|
13 remote machines using a password-less ssh keypair. They are not meant |
|
14 to be used directly. Subclass them! |
|
15 |
|
16 See the rdoc for additional information and examples. |
|
17 |
|
18 |
|
19 == Options |
|
20 |
|
21 Symphony-ssh uses |
|
22 Configurability[https://rubygems.org/gems/configurability] to determine |
|
23 behavior. The configuration is a YAML[http://www.yaml.org/] file. |
|
24 |
|
25 symphony_ssh: |
|
26 path: /usr/bin/ssh |
|
27 user: root |
|
28 key: /path/to/a/private_key.rsa |
|
29 opts: |
|
30 - -e |
|
31 - none |
|
32 - -T |
|
33 - -x |
|
34 - -o |
|
35 - CheckHostIP=no' |
|
36 - -o |
|
37 - BatchMode=yes' |
|
38 - -o |
|
39 - StrictHostKeyChecking=no |
|
40 |
|
41 |
|
42 |
|
43 === path |
|
44 |
|
45 The absolute path to the ssh binary. |
|
46 |
|
47 === user |
|
48 |
|
49 The default user to connect to remote hosts with. This can be |
|
50 changes per connection in the AMQP payload. |
|
51 |
|
52 === key |
|
53 |
|
54 An absolute path to a password-less ssh private key. |
|
55 |
|
56 === opts |
|
57 |
|
58 SSH client options, passed to the ssh binary on the command line. Note |
|
59 that the defaults have been tested fairly extensively, these are just |
|
60 exposed if you have very specific needs and you know what you're doing. |
|
61 |
|
62 |
|
63 == Installation |
|
64 |
|
65 gem install symphony-ssh |
|
66 |
|
67 |
|
68 == Contributing |
|
69 |
|
70 You can check out the current development source with Mercurial via its |
|
71 {project page}[http://bitbucket.org/mahlon/symphony-metronome]. |
|
72 |
|
73 After checking out the source, run: |
|
74 |
|
75 $ rake |
|
76 |
|
77 This task will run the tests/specs and generate the API documentation. |
|
78 |
|
79 If you use {rvm}[http://rvm.io/], entering the project directory will |
|
80 install any required development dependencies. |
|
81 |
|
82 |
|
83 == License |
|
84 |
|
85 Copyright (c) 2014, Mahlon E. Smith and Michael Granger |
|
86 All rights reserved. |
|
87 |
|
88 Redistribution and use in source and binary forms, with or without |
|
89 modification, are permitted provided that the following conditions are met: |
|
90 |
|
91 * Redistributions of source code must retain the above copyright notice, |
|
92 this list of conditions and the following disclaimer. |
|
93 |
|
94 * Redistributions in binary form must reproduce the above copyright notice, |
|
95 this list of conditions and the following disclaimer in the documentation |
|
96 and/or other materials provided with the distribution. |
|
97 |
|
98 * Neither the name of the author/s, nor the names of the project's |
|
99 contributors may be used to endorse or promote products derived from this |
|
100 software without specific prior written permission. |
|
101 |
|
102 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
|
103 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
|
104 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
|
105 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE |
|
106 FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
|
107 DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
|
108 SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
|
109 CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
|
110 OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
|
111 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
|
112 |
|
113 |