tabs are evil
[mirror/dsa-wiki.git] / input / howto / new-machine.creole
index b7d4f6d..f73c2da 100644 (file)
@@ -1,6 +1,6 @@
 == setup/integrate a new machine ==
 
-Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup]].  If stuff breaks fix it :)
+Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup]].  If stuff breaks fix it.
 
 
 * install ssh if it isn't there already
@@ -8,12 +8,6 @@ Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup
     apt-get install ssh
 }}}
 
-* make apt sane
-{{{
-    echo 'Acquire::PDiffs "false";' > /etc/apt/apt.conf.d/local-pdiff
-    echo 'APT::Install-Recommends 0;' > /etc/apt/apt.conf.d/local-recommends
-}}}
-
 * sane locales: (make sure there is _no_ locale defined in /etc/environment and /etc/default/locale)
 {{{
    echo -n > /etc/environment
@@ -34,12 +28,12 @@ Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup
 
 * setup [[puppet|howto/puppet-setup]]  (run the puppet client two or three times until things converge.)
 
-* on draghi, add the host to /home/sshdist/.ssh/authorized_keys and generate.conf
+* on draghi, add the host to /home/sshdist/.ssh/authorized_keys
 (you want the host's rsa host key there: {{{cat /etc/ssh/ssh_host_rsa_key.pub}}})
 {{{
     : :: draghi :: && sudo vi /home/sshdist/.ssh/authorized_keys
-    : :: draghi :: && sudo vi /etc/userdir-ldap/generate.conf
 }}}
+* use ud-host to add the new host to LDAP
 * run generate, or wait until cron runs it for you
 {{{
     : :: draghi :: && sudo -u sshdist ud-generate
@@ -72,7 +66,7 @@ Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup
 
 * install debian.org which brings you shells and much other fun
 {{{
-    apt-get install debian.org
+    apt-get install debian.org debian.org-recommended
 }}}
 
 * in /etc/ssh/sshd_config:
@@ -118,12 +112,12 @@ Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup
 
 * Add debian-admin@debian.org to root in /etc/aliases
 {{{
-       if ! egrep '^root:' /etc/aliases > /dev/null; then
-               echo "root: debian-admin@debian.org" >> /etc/aliases
-       elif ! egrep '^root:.*debian-admin@debian.org' /etc/aliases > /dev/null; then
-               sed -i -e 's/^root: .*/&, debian-admin@debian.org/' /etc/aliases
-       fi
-       newaliases
+  if ! egrep '^root:' /etc/aliases > /dev/null; then
+    echo "root: debian-admin@debian.org" >> /etc/aliases
+  elif ! egrep '^root:.*debian-admin@debian.org' /etc/aliases > /dev/null; then
+    sed -i -e 's/^root: .*/&, debian-admin@debian.org/' /etc/aliases
+  fi
+  newaliases
 }}}
 
 * sane default editor
@@ -142,6 +136,4 @@ Note: this has recently been changed to rely more on [[puppet|howto/puppet-setup
 
 * add to nagios
 
-* add host to ldap: ud-host -a $USER -h ....
-
 -- weasel, Wed, 04 Jun 2008 20:52:56 +0200