You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+19Lines changed: 19 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -21,6 +21,25 @@ Deploys SSH keys
21
21
|`authorized_keys`| Array |`[]`| Array of strings representing authorized SSH public keys |
22
22
|`authorized_users`| Array |`[]`| Array of strings representing authorized users (found in the databag) |
23
23
24
+
## LWRP
25
+
26
+
This cookbook provides one resource:
27
+
28
+
### `ssh_keys_key`
29
+
30
+
```ruby
31
+
ssh_keys_key 'john'do
32
+
authorized_keys [
33
+
'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDmz4D...',
34
+
'ssh-rsa sFE5JafGV4UmfxGP5/vpAAADWC8HcoQAyYT...'
35
+
]
36
+
authorized_users %w(bob joe)
37
+
end
38
+
39
+
```
40
+
41
+
This resource will add authorized keys from the provided list (`authorized_keys`) and from users declared in the databag (`bob` and `joe`) to the `john` user.
42
+
24
43
## Databag
25
44
26
45
The databag is an `Hash` with usernames as keys. Each user can have a list of keypairs (as an `Array`).
0 commit comments