aboutsummaryrefslogtreecommitdiff
path: root/manifests/defines/ssh_local_key.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/defines/ssh_local_key.pp')
-rw-r--r--manifests/defines/ssh_local_key.pp43
1 files changed, 0 insertions, 43 deletions
diff --git a/manifests/defines/ssh_local_key.pp b/manifests/defines/ssh_local_key.pp
deleted file mode 100644
index 57bb251..0000000
--- a/manifests/defines/ssh_local_key.pp
+++ /dev/null
@@ -1,43 +0,0 @@
-# Manage local ssh keys
-define ssh_local_key(
- $owner = $name,
- $group = $name,
- $home = "/home/${owner}",
- $source = "puppet:///ssh/${name}_id_rsa",
- $dest = 'id_rsa',
- $ensure = 'present',
-) {
- ssh_folder { "ssh_local_key-${name}":
- home => $home,
- owner => $owner,
- group => $group,
- ensure => $ensure ? {
- 'present' => 'directory',
- default => 'absent',
- },
- }
-
- file { "${home}/.ssh/${dest}":
- ensure => $ensure,
- owner => $owner,
- group => $group,
- mode => 0400,
- source => $ensure ? {
- 'present' => $source,
- default => undef,
- },
- require => File["${home}/.ssh"],
- }
-
- file { "${home}/.ssh/${dest}.pub":
- ensure => $ensure,
- owner => $owner,
- group => $group,
- mode => 0400,
- source => $ensure ? {
- 'present' => "${source}.pub",
- default => undef,
- },
- require => File["${home}/.ssh"],
- }
-}