]> gitweb.fluxo.info Git - hydra.git/commitdiff
Redirection fixes
authorSilvio Rhatto <rhatto@riseup.net>
Thu, 24 Sep 2015 17:12:01 +0000 (14:12 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Thu, 24 Sep 2015 17:12:01 +0000 (14:12 -0300)
README.md
share/hydractl/provision

index 23073b600e66fcd990b80d34712af07a31a0dc4a..b1021463e0539b19647019560b35451c4a73958d 100644 (file)
--- a/README.md
+++ b/README.md
@@ -28,7 +28,7 @@ Then check the source integrity of the latest release:
 Finally, add hydra folder to your `$PATH` or run the following command to install
 it under `/usr/local`:
 
-    ./hydractl deploy
+    ./hydractl install
 
 Managing an existing network
 ----------------------------
@@ -54,4 +54,4 @@ Major direct upstreams:
 
 * [https://www.debian.org Debian].
 * [http://docs.puppetlabs.com Puppet].
-* [Shared Puppet Modules Initiative](https://labs.riseup.net/code/projects/sharedpuppetmodules).
+* [Shared Puppet Modules Initiative](https://gitlab.com/groups/shared-puppet-modules-group).
index 53cab778c7cf42ab032f860c245f24b224d40405..a5191bebd906cb8c01dae3768c05e793ab151c0f 100755 (executable)
@@ -288,20 +288,20 @@ echo "Applying initial configuration..."
 hydra_sudo_run mount none -t proc $WORK/proc
 hydra_sudo_run mount none -t sysfs $WORK/sys
 hydra_sudo_run mount -o bind /dev/ $WORK/dev
-echo LANG=C | $SUDO tee $WORK/etc/default/locale
+echo LANG=C | $SUDO tee $WORK/etc/default/locale > /dev/null
 
 # Resolver configuration.
-echo "domain $domain"            | $SUDO tee    $WORK/etc/resolv.conf
-echo "search $hostname.$domain"  | $SUDO tee -a $WORK/etc/resolv.conf
-grep nameserver /etc/resolv.conf | $SUDO tee -a $WORK/etc/resolv.conf
+echo "domain $domain"            | $SUDO tee    $WORK/etc/resolv.conf > /dev/null
+echo "search $hostname.$domain"  | $SUDO tee -a $WORK/etc/resolv.conf > /dev/null
+grep nameserver /etc/resolv.conf | $SUDO tee -a $WORK/etc/resolv.conf > /dev/null
 
 # Hostname configuration.
-echo $hostname.$domain                       | $SUDO tee    $WORK/etc/hostname
-echo "127.0.0.1 localhost"                   | $SUDO tee -a $WORK/etc/hosts
-echo "127.0.0.1 $hostname $hostname.$domain" | $SUDO tee -a $WORK/etc/hosts
+echo $hostname.$domain                       | $SUDO tee    $WORK/etc/hostname > /dev/null
+echo "127.0.0.1 localhost"                   | $SUDO tee -a $WORK/etc/hosts    > /dev/null
+echo "127.0.0.1 $hostname $hostname.$domain" | $SUDO tee -a $WORK/etc/hosts    > /dev/null
 
 # Invert hostname contents to avoid http://projects.puppetlabs.com/issues/2533
-tac $WORK/etc/hosts | $SUDO tee $WORK/etc/hosts.new
+tac $WORK/etc/hosts | $SUDO tee $WORK/etc/hosts.new > /dev/null
 hydra_sudo_run mv $WORK/etc/hosts.new $WORK/etc/hosts
 
 # Initial upgrade.
@@ -312,64 +312,64 @@ hydra_sudo_run chroot $WORK/ apt-get install locales cryptsetup lvm2 initramfs-t
 
 # Crypttab.
 echo "Configuring crypttab..."
-echo "# <target name> <source device>   <key file>  <options>" | $SUDO tee $WORK/etc/crypttab
+echo "# <target name> <source device>   <key file>  <options>" | $SUDO tee $WORK/etc/crypttab > /dev/null
 
 if [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee $WORK/etc/crypttab
+  cat <<-EOF | $SUDO tee $WORK/etc/crypttab > /dev/null
 root            /dev/mapper/$vg-root      none            luks
 EOF
 fi
 
 if [ "$home_size" != "0" ] && [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab > /dev/null
 home            /dev/mapper/$vg-home      none            luks
 EOF
 fi
 
 if [ "$var_size" != "0" ] && [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab > /dev/null
 var             /dev/mapper/$vg-var       none            luks
 EOF
 fi
 
 if [ "$swap_size" != "0" ] && [ "$random_swap" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab > /dev/null
 swap            /dev/mapper/$vg-swap      /dev/random     swap,cipher=aes-xts-plain64:sha256
 EOF
 fi
 
 if [ "$swap_size" != "0" ] && [ "$random_swap" != "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/crypttab > /dev/null
 swap            /dev/mapper/$vg-swap      none        luks,swap
 EOF
 fi
 
 # Fstab.
 echo "Configuring fstab..."
-echo "" | $SUDO tee $WORK/etc/fstab
+echo "" | $SUDO tee $WORK/etc/fstab > /dev/null
 if [ "$swap_size" != "0" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/swap      none           swap  sw                                 0 0
 EOF
 fi
 
 if [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/root      /              ext4  defaults,errors=remount-ro         0 1
 EOF
 else
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/$vg-root   /              ext4  defaults,errors=remount-ro         0 1
 EOF
 fi
 
 if [ "$home_size" != "0" ]; then
   if [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/home      /home          ext4  defaults,errors=remount-ro         0 2
 EOF
   else
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/$vg-home   /home          ext4  defaults,errors=remount-ro         0 2
 EOF
   fi
@@ -377,11 +377,11 @@ fi
 
 if [ "$var_size" != "0" ]; then
   if [ "$encrypt" == "y" ]; then
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/var       /var           ext4  defaults,errors=remount-ro         0 2
 EOF
   else
-  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab
+  cat <<-EOF | $SUDO tee -a $WORK/etc/fstab > /dev/null
 /dev/mapper/$vg-var    /var           ext4  defaults,errors=remount-ro         0 2
 EOF
   fi
@@ -392,7 +392,7 @@ if [ "$grub" == "y" ]; then
   echo "Boot device setup..."
   hydra_sudo_run mkfs.ext4 $boot_device
   hydra_sudo_run mount $boot_device $WORK/boot
-  echo "$reboot_device /boot ext4 defaults,errors=remount-ro 0 2" | $SUDO tee -a $WORK/etc/fstab
+  echo "$reboot_device /boot ext4 defaults,errors=remount-ro 0 2" | $SUDO tee -a $WORK/etc/fstab > /dev/null
 
   echo "Setting up GRUB..."
   hydra_sudo_run chroot $WORK/ apt-get install grub-pc -y
@@ -400,7 +400,7 @@ fi
 
 # Kernel.
 echo "Installing kernel..."
-cat <<-EOF | $SUDO tee $WORK/etc/initramfs-tools/modules
+cat <<-EOF | $SUDO tee $WORK/etc/initramfs-tools/modules > /dev/null
 dm-mod
 dm-crypt
 dm-raid
@@ -409,7 +409,7 @@ twofish
 sha256
 EOF
 
-cat <<-EOF | $SUDO tee $WORK/etc/kernel-img.conf
+cat <<-EOF | $SUDO tee $WORK/etc/kernel-img.conf > /dev/null
 do_initrd = Yes
 EOF