summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--jenkins-nodes-home/authorized_keys1
-rwxr-xr-xupdate_jdn.sh12
2 files changed, 10 insertions, 3 deletions
diff --git a/jenkins-nodes-home/authorized_keys b/jenkins-nodes-home/authorized_keys
new file mode 100644
index 00000000..bfd27d6d
--- /dev/null
+++ b/jenkins-nodes-home/authorized_keys
@@ -0,0 +1 @@
+ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDSPYH1KKv6PsW0IgNcPbI/l2rjhxPaOGT/lbgaPzVjwPWlqHAEB0PctzNzkduRiaEMhTmcDTCsMOVkBGiPMmuBltqzpGSjcAc3v/sDYaDn+Onj5pTaG8HBMKqxOQP9I24xNjb21tRrmRSDAUrSHHiEm2Lu64efA3vE/L447ZYs53aLd2fBt0zoFKHswasFR57y6y9/3VJTdAnGrAIq9QxnMi2Tbg/KZDiYYmodfCMrAnATTkwGntcINz7FO/HAxHAs1YryzuoDOA02Xqxg4uzlxQgkL91/OhKVKd+2TBg+FAVUkiCKY+uSCdgN1yjoUa0fPFaWEbtEwrWfZgIAIINf jenkins@jenkins
diff --git a/update_jdn.sh b/update_jdn.sh
index fd466740..dcf29d8b 100755
--- a/update_jdn.sh
+++ b/update_jdn.sh
@@ -259,7 +259,9 @@ if [ "$HOSTNAME" = "jenkins" ] ; then
fi
cd /etc/munin/plugins ; sudo rm -f postfix_* open_inodes df_inode interrupts irqstats threads proc_pri vmstat if_err_eth0 fw_forwarded_local fw_packets forks open_files users 2>/dev/null
-[ -L apache_accesses ] || for i in apache_accesses apache_volume ; do sudo ln -s /usr/share/munin/plugins/$i $i ; done
+if [ "$HOSTNAME" = "jenkins" ] ; then
+ [ -L apache_accesses ] || for i in apache_accesses apache_volume ; do sudo ln -s /usr/share/munin/plugins/$i $i ; done
+fi
explain "Packages configured."
sudo service munin-node force-reload
@@ -272,8 +274,12 @@ for dir in bin logparse job-cfg features live ; do
sudo chown -R jenkins-adm.jenkins-adm /srv/jenkins/$dir
done
sudo mkdir -p /var/lib/jenkins/.ssh
-sudo cp jenkins-home/procmailrc /var/lib/jenkins/.procmailrc
-sudo cp jenkins-home/authorized_keys /var/lib/jenkins/.ssh/authorized_keys
+if [ "$HOSTNAME" = "jenkins" ] ; then
+ sudo cp jenkins-home/procmailrc /var/lib/jenkins/.procmailrc
+ sudo cp jenkins-home/authorized_keys /var/lib/jenkins/.ssh/authorized_keys
+else
+ sudo cp jenkins-nodes-home/authorized_keys /var/lib/jenkins/.ssh/authorized_keys
+fi
sudo chown -R jenkins:jenkins /var/lib/jenkins/.ssh
sudo chmod 700 /var/lib/jenkins/.ssh
sudo chmod 600 /var/lib/jenkins/.ssh/authorized_keys