Last active
August 29, 2015 14:03
-
-
Save michaeltchapman/e2962dae3e650d8187ad to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$my_hash = { 'foo1' => {'user' => 'a', 'pass' => 'p', 'ip' => '1.2.3.4'}, 'foo2' => {'user' => 'b', 'pass' => 'p', 'ip' => '4.5.6.7'}} | |
create_resources(do_thing, $my_hash) | |
define do_thing(user, pass, ip) { | |
exec {'do_something': | |
command => "ssh -l ${user} ${ip} < ${pass}" | |
} | |
} | |
# ... will create two do_things, foo1 and foo2, with the specified params. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment