Mark Bergsma has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/105210


Change subject: Add RANCID .cloginrc file
......................................................................

Add RANCID .cloginrc file

The password is pulled from the private repo

Change-Id: Ic0c94773af80b5aff8dfdeb63344b53d3b216383
---
M manifests/misc/rancid.pp
A templates/rancid/cloginrc.erb
2 files changed, 19 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/10/105210/1

diff --git a/manifests/misc/rancid.pp b/manifests/misc/rancid.pp
index bf59acf..62369c1 100644
--- a/manifests/misc/rancid.pp
+++ b/manifests/misc/rancid.pp
@@ -11,6 +11,8 @@
                name => 'rancid'
        }
 
+       include passwords::rancid
+
        file { '/etc/rancid/rancid.conf':
                require => Package['rancid'],
                owner => root,
@@ -28,6 +30,14 @@
                source => "puppet:///files/misc/rancid/core";
        }
 
+       file { '/var/lib/rancid/.cloginrc':
+               require => Package['rancid'],
+               owner => rancid,
+               group => rancid,
+               mode => 0440,
+               content => template('rancid/cloginrc.erb')
+       }
+
        file { '/etc/cron.d/rancid':
                require => File['/var/lib/rancid/core'],
                owner => root,
diff --git a/templates/rancid/cloginrc.erb b/templates/rancid/cloginrc.erb
new file mode 100644
index 0000000..db8b23b
--- /dev/null
+++ b/templates/rancid/cloginrc.erb
@@ -0,0 +1,9 @@
+add autoenable csw1-sdtpa.wikimedia.org {1}
+add autoenable asw-d1-sdtpa.mgmt.pmtpa.wmnet {1}
+add autoenable asw-d2-sdtpa.mgmt.pmtpa.wmnet {1}
+add autoenable asw-d3-sdtpa.mgmt.pmtpa.wmnet {1}
+add autoenable asw-a4-sdtpa.mgmt.pmtpa.wmnet {1}
+add autoenable asw-a5-sdtpa.mgmt.pmtpa.wmnet {1}
+
+add method * {ssh}
+add password * {<%= scope.lookupvar("passwords::rancid::rancidpass") %>}
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/105210
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic0c94773af80b5aff8dfdeb63344b53d3b216383
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Mark Bergsma <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to