summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Farrellee <matt@redhat.com>2013-07-10 15:39:27 -0400
committerMatthew Farrellee <matt@redhat.com>2013-07-12 07:54:03 -0400
commitb7def9d8c36f8f1f3066cb219704de2fd00409ee (patch)
treedb2fde680da328e463a9ad8a69ec6667f540f3d1
parent0092ac37dfb00cc344eed64e3f2ae424475a7303 (diff)
Merge Ubuntu and Fedora instructions for ssh/sshd setup
Notes
Notes (review): Verified+2: Jenkins Approved+1: Sergey Lukjanov <slukjanov@mirantis.com> Code-Review+2: Sergey Lukjanov <slukjanov@mirantis.com> Code-Review+1: Alexander Ignatov <aignatov@mirantis.com> Code-Review+1: Ivan Berezovskiy <iberezovskiy@mirantis.com> Submitted-by: Jenkins Submitted-at: Mon, 15 Jul 2013 14:46:51 +0000 Reviewed-on: https://review.openstack.org/36537 Project: stackforge/savanna-extra Branch: refs/heads/master
-rwxr-xr-xelements/hadoop_fedora/post-install.d/13-connection-setup59
1 files changed, 45 insertions, 14 deletions
diff --git a/elements/hadoop_fedora/post-install.d/13-connection-setup b/elements/hadoop_fedora/post-install.d/13-connection-setup
index 8f02245..0913425 100755
--- a/elements/hadoop_fedora/post-install.d/13-connection-setup
+++ b/elements/hadoop_fedora/post-install.d/13-connection-setup
@@ -8,21 +8,52 @@ echo "Adjusting ssh configuration"
8# Note1: augtool on Ubuntu does not auto-save, pass -s 8# Note1: augtool on Ubuntu does not auto-save, pass -s
9install-packages augeas openssh-server openssh-clients 9install-packages augeas openssh-server openssh-clients
10 10
11augtool set /files/etc/ssh/sshd_config/PasswordAuthentication yes
12augtool set /files/etc/ssh/sshd_config/UseDNS no
13augtool set /files/etc/ssh/sshd_config/PermitTunnel yes
14augtool set /files/etc/ssh/sshd_config/SyslogFacility AUTH
15augtool set /files/etc/ssh/sshd_config/PermitRootLogin yes
16augtool set /files/etc/ssh/sshd_config/StrictModes yes
17augtool set /files/etc/ssh/sshd_config/RSAAuthentication yes
18augtool set /files/etc/ssh/sshd_config/PubkeyAuthentication yes
19augtool set /files/etc/ssh/sshd_config/IgnoreRhosts yes
20
21augtool set /files/etc/ssh/ssh_config/Host/StrictHostKeyChecking no
22augtool set /files/etc/ssh/ssh_config/Host/GSSAPIDelegateCredentials no
23augtool set /files/etc/ssh/ssh_config/Host/GSSAPIAuthentication no
24 11
12##
13## ssh server configuration
14##
15
16# Unique to Ubuntu
17augtool -s set /files/etc/ssh/sshd_config/PasswordAuthentication yes
18augtool -s set /files/etc/ssh/sshd_config/GSSAPICleanupCredentials yes
19augtool -s set /files/etc/ssh/sshd_config/AuthorizedKeysFile .ssh/authorized_keys
20
21# Unique to Fedora
22augtool -s set /files/etc/ssh/sshd_config/SyslogFacility AUTH
23augtool -s set /files/etc/ssh/sshd_config/PermitRootLogin yes
24augtool -s set /files/etc/ssh/sshd_config/StrictModes yes
25augtool -s set /files/etc/ssh/sshd_config/RSAAuthentication yes
26augtool -s set /files/etc/ssh/sshd_config/PubkeyAuthentication yes
27augtool -s set /files/etc/ssh/sshd_config/IgnoreRhosts yes
28
29# Common
30augtool -s set /files/etc/ssh/sshd_config/GSSAPIAuthentication no
31augtool -s set /files/etc/ssh/sshd_config/UseDNS no
32augtool -s set /files/etc/ssh/sshd_config/PermitTunnel yes
33
34
35##
36## ssh client configuration
37##
38
39# Unique to Ubuntu
40#none
41
42# Unique to Fedora
43augtool -s set /files/etc/ssh/ssh_config/Host/GSSAPIDelegateCredentials no
44
45# Common
46augtool -s set /files/etc/ssh/ssh_config/Host/StrictHostKeyChecking no
47augtool -s set /files/etc/ssh/ssh_config/Host/GSSAPIAuthentication no
48
49
50##
51## Misc configuration
52##
53
54# Unique to Fedora
25# No known augeas lense for cloud-init config 55# No known augeas lense for cloud-init config
26sed -i 's/ssh_pwauth: 0/ssh_pwauth: 1/' /etc/cloud/cloud.cfg 56sed -i 's/ssh_pwauth: 0/ssh_pwauth: 1/' /etc/cloud/cloud.cfg
27 57
28augtool clear /files/etc/sudoers/Defaults[type=':nrpe']/requiretty/negate 58# Unique to Fedora
59augtool -s clear /files/etc/sudoers/Defaults[type=':nrpe']/requiretty/negate