From 9e1c6791342fb991a4b7e8d67b37a56765312322 Mon Sep 17 00:00:00 2001 From: "martin f. krafft" Date: Wed, 13 Sep 2017 15:26:55 +0200 Subject: [PATCH] change to stretch suite --- di-update | 2 +- .../commands/early_command | 0 .../{jessie => stretch}/commands/late_command | 0 .../late_commands.d/ansible_dependencies | 0 .../commands/late_commands.d/ansible_user | 0 .../late_commands.d/debconf_readline_low | 0 .../late_commands.d/enable_serial_console | 0 .../mask_systemd-logind-service | 0 .../late_commands.d/no_kernel_symlinks | 0 .../late_commands.d/post_boot_cleanup | 0 .../commands/late_commands.d/srv-home_symlink | 0 preseed/{jessie => stretch}/preseed.cfg | 0 preseed/wheezy/commands/early_command | 2 - preseed/wheezy/commands/late_command | 4 - .../late_commands.d/ansible_dependencies | 5 - .../commands/late_commands.d/ansible_user | 26 ---- .../late_commands.d/enable_serial_console | 9 -- .../late_commands.d/install_salt_backport | 34 ----- .../late_commands.d/no_kernel_symlinks | 4 - .../late_commands.d/post_boot_cleanup | 15 -- .../commands/late_commands.d/srv-home_symlink | 7 - preseed/wheezy/preseed.cfg | 133 ------------------ vinst | 2 +- 23 files changed, 2 insertions(+), 241 deletions(-) rename preseed/{jessie => stretch}/commands/early_command (100%) rename preseed/{jessie => stretch}/commands/late_command (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/ansible_dependencies (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/ansible_user (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/debconf_readline_low (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/enable_serial_console (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/mask_systemd-logind-service (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/no_kernel_symlinks (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/post_boot_cleanup (100%) rename preseed/{jessie => stretch}/commands/late_commands.d/srv-home_symlink (100%) rename preseed/{jessie => stretch}/preseed.cfg (100%) delete mode 100755 preseed/wheezy/commands/early_command delete mode 100755 preseed/wheezy/commands/late_command delete mode 100755 preseed/wheezy/commands/late_commands.d/ansible_dependencies delete mode 100755 preseed/wheezy/commands/late_commands.d/ansible_user delete mode 100755 preseed/wheezy/commands/late_commands.d/enable_serial_console delete mode 100755 preseed/wheezy/commands/late_commands.d/install_salt_backport delete mode 100755 preseed/wheezy/commands/late_commands.d/no_kernel_symlinks delete mode 100755 preseed/wheezy/commands/late_commands.d/post_boot_cleanup delete mode 100755 preseed/wheezy/commands/late_commands.d/srv-home_symlink delete mode 100644 preseed/wheezy/preseed.cfg diff --git a/di-update b/di-update index 2e4a8b1..05e4586 100755 --- a/di-update +++ b/di-update @@ -5,7 +5,7 @@ set -eu : ${SUBDIR:=debian/dists/%SUITE%/main/installer-%ARCH%/current/images} : ${ARCHS:=amd64} -: ${SUITES:=wheezy jessie} +: ${SUITES:=stretch} #: ${MIRROR_jessie:=http://d-i.debian.org} #: ${SUBDIR_jessie:=daily-images/%ARCH%/daily/} diff --git a/preseed/jessie/commands/early_command b/preseed/stretch/commands/early_command similarity index 100% rename from preseed/jessie/commands/early_command rename to preseed/stretch/commands/early_command diff --git a/preseed/jessie/commands/late_command b/preseed/stretch/commands/late_command similarity index 100% rename from preseed/jessie/commands/late_command rename to preseed/stretch/commands/late_command diff --git a/preseed/jessie/commands/late_commands.d/ansible_dependencies b/preseed/stretch/commands/late_commands.d/ansible_dependencies similarity index 100% rename from preseed/jessie/commands/late_commands.d/ansible_dependencies rename to preseed/stretch/commands/late_commands.d/ansible_dependencies diff --git a/preseed/jessie/commands/late_commands.d/ansible_user b/preseed/stretch/commands/late_commands.d/ansible_user similarity index 100% rename from preseed/jessie/commands/late_commands.d/ansible_user rename to preseed/stretch/commands/late_commands.d/ansible_user diff --git a/preseed/jessie/commands/late_commands.d/debconf_readline_low b/preseed/stretch/commands/late_commands.d/debconf_readline_low similarity index 100% rename from preseed/jessie/commands/late_commands.d/debconf_readline_low rename to preseed/stretch/commands/late_commands.d/debconf_readline_low diff --git a/preseed/jessie/commands/late_commands.d/enable_serial_console b/preseed/stretch/commands/late_commands.d/enable_serial_console similarity index 100% rename from preseed/jessie/commands/late_commands.d/enable_serial_console rename to preseed/stretch/commands/late_commands.d/enable_serial_console diff --git a/preseed/jessie/commands/late_commands.d/mask_systemd-logind-service b/preseed/stretch/commands/late_commands.d/mask_systemd-logind-service similarity index 100% rename from preseed/jessie/commands/late_commands.d/mask_systemd-logind-service rename to preseed/stretch/commands/late_commands.d/mask_systemd-logind-service diff --git a/preseed/jessie/commands/late_commands.d/no_kernel_symlinks b/preseed/stretch/commands/late_commands.d/no_kernel_symlinks similarity index 100% rename from preseed/jessie/commands/late_commands.d/no_kernel_symlinks rename to preseed/stretch/commands/late_commands.d/no_kernel_symlinks diff --git a/preseed/jessie/commands/late_commands.d/post_boot_cleanup b/preseed/stretch/commands/late_commands.d/post_boot_cleanup similarity index 100% rename from preseed/jessie/commands/late_commands.d/post_boot_cleanup rename to preseed/stretch/commands/late_commands.d/post_boot_cleanup diff --git a/preseed/jessie/commands/late_commands.d/srv-home_symlink b/preseed/stretch/commands/late_commands.d/srv-home_symlink similarity index 100% rename from preseed/jessie/commands/late_commands.d/srv-home_symlink rename to preseed/stretch/commands/late_commands.d/srv-home_symlink diff --git a/preseed/jessie/preseed.cfg b/preseed/stretch/preseed.cfg similarity index 100% rename from preseed/jessie/preseed.cfg rename to preseed/stretch/preseed.cfg diff --git a/preseed/wheezy/commands/early_command b/preseed/wheezy/commands/early_command deleted file mode 100755 index 8f26221..0000000 --- a/preseed/wheezy/commands/early_command +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -# pwd is / diff --git a/preseed/wheezy/commands/late_command b/preseed/wheezy/commands/late_command deleted file mode 100755 index 3f843be..0000000 --- a/preseed/wheezy/commands/late_command +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -cp -r /commands/late_commands.d /target -in-target run-parts /late_commands.d -rm -r /target/late_commands.d diff --git a/preseed/wheezy/commands/late_commands.d/ansible_dependencies b/preseed/wheezy/commands/late_commands.d/ansible_dependencies deleted file mode 100755 index 8480af1..0000000 --- a/preseed/wheezy/commands/late_commands.d/ansible_dependencies +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -echo "Installing Ansible dependencies" -export DEBCONF_FRONTEND=noninteractive -apt-get install --no-install-recommends -y python-minimal python-apt python-yaml python-simplejson diff --git a/preseed/wheezy/commands/late_commands.d/ansible_user b/preseed/wheezy/commands/late_commands.d/ansible_user deleted file mode 100755 index 10adacd..0000000 --- a/preseed/wheezy/commands/late_commands.d/ansible_user +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh - -export DEBCONF_FRONTEND=noninteractive -apt-get install -y sudo - -USER=ansible -echo "Adding $USER user and installing SSH key" - -HOME=/var/lib/$USER -adduser --home $HOME --shell /bin/sh \ - --uid 999 --gid 65534 --disabled-password \ - --gecos 'Remote control with ansible' $USER - -install -d -m 700 -o $USER -g nogroup $HOME/.ssh -cat <<_eof > $HOME/.ssh/authorized_keys -no-agent-forwarding,no-port-forwarding,no-user-rc,no-X11-forwarding ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDGUrO3VGYap3uyphcExiA4VXjXzwyiqXA4kD3o3uLi45Lw9TFCefwa815R4JkRhaGs/4pqy4Bqcmb6kbEOEaTS6xidedQOcuHIxk6nZfDAhGm95rmx1kSxgLIBYJn0RPFvdRiFuoGC07tn4FRQ/seiTVbbTtgy7Wrb3XqFMPhBp1EFfe0ASZdEUJ/EfZl/a72y/57DTflL6RzPIWF6t0z5URURSm3caC4Uxpvx3FK37xzXOd0il7ikv1UeC5pMopwR74zb9SfFiPVEcOK64jq8xnS7ugTOrlb+H5JwchOO88eUTD1pd72+4a7XkeHzneXT8mNROQJZUU1vxoJpZXFziL0uCtnR9QVt+/mE4q3MiYjq5YYOXYCJ0vKIDKVAkxv3U71N8WpnasLmC5mal7juuj8tHXqQJc8bNt7ZxoSRESwRjhIXmoIxdkso862KTM7FL5SKPGDwE8ifog4OU3PcI8C5dfTY1vMa7mZszsO3sK1+gpiJBUlWu0nv9Q2qB3KDPoKA/VnPGBitQSIMbFgDfUs/JXJ35q4ynxO/h0NqCPGXx1bECc6meepND99qo301kYPxYLY4FVeFMVJbcdS/kn0YxbMikaRmr3SqxaRUb4vl1NDKdtoIcIyS0Gh4AvTYtxlLZwShf8ImtRzLerLwqx73WWSIeNai+pHJJNTMvw== madduck@fishbowl -_eof -chmod -R u=rwX,og= $HOME -chown -R ${USER}.nogroup $HOME - -SUDOFILE=/etc/sudoers.d/local-ansible-user -cat <<_eof > $SUDOFILE -Defaults>ansible !requiretty -$USER $(hostname --fqdn)=(root) NOPASSWD: ALL -_eof -chmod 440 $SUDOFILE diff --git a/preseed/wheezy/commands/late_commands.d/enable_serial_console b/preseed/wheezy/commands/late_commands.d/enable_serial_console deleted file mode 100755 index 09f8acb..0000000 --- a/preseed/wheezy/commands/late_commands.d/enable_serial_console +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh -echo "Enabling the serial console..." -#683124 requires the cmdline patch, and #444026 is for GRUB_TERMINAL: -sed -i -e '/^GRUB_CMDLINE_LINUX=/s/"$/ console=tty0 console=ttyS0,115200n8&/' \ - -e '/^GRUB_CMDLINE_LINUX=/s/=" /="/' \ - -e '/^GRUB_TERMINAL=/s/serial/"& console"/' \ - /etc/default/grub -update-grub -sed -i '/ttyS0/s/^#//;/ttyS0/s/9600 vt100/115200 linux/' /etc/inittab diff --git a/preseed/wheezy/commands/late_commands.d/install_salt_backport b/preseed/wheezy/commands/late_commands.d/install_salt_backport deleted file mode 100755 index 050d23c..0000000 --- a/preseed/wheezy/commands/late_commands.d/install_salt_backport +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -TMPLIST=/etc/apt/sources.list.d/tmp-backports.list - -echo "Temporarily enabling backports" -sed -ne 's/-updates/-backports/p' /etc/apt/sources.list > $TMPLIST - -SUITE=$(tail -1 $TMPLIST | cut -d' ' -f3) -SUITE=${SUITE%-*} - -cat <<_eof >> $TMPLIST -deb http://debian.saltstack.com/debian ${SUITE}-saltstack main -_eof - -cd /tmp -wget -O salt.gpg http://debian.saltstack.com/debian-salt-team-joehealy.gpg.key -echo "145157dfb896f7a0c1f390c6f72e6d092fbbfaf4374b510d4c7828c4177ab476 salt.gpg" | sha256sum -c || exit 1 -apt-key --keyring /etc/apt/trusted.gpg.d/salt.gpg add salt.gpg && rm salt.gpg - -apt-get update - -rm -f /etc/apt/trusted.gpg.d/salt.gpg - -TMPCONF=/etc/default/salt-minion - -echo "exit 0" > $TMPCONF - -echo "Installing Salt minion (possibly from $SUITE-backports and $SUITE-saltstack)" -export DEBCONF_FRONTEND=noninteractive -apt-get install --no-install-recommends -t $SUITE-saltstack -y salt-minion - -echo "pki_dir: /var/lib/salt/minion/pki" > /etc/salt/minion.d/tmp-pki-in-varlib.conf - -rm -f $TMPLIST $TMPCONF diff --git a/preseed/wheezy/commands/late_commands.d/no_kernel_symlinks b/preseed/wheezy/commands/late_commands.d/no_kernel_symlinks deleted file mode 100755 index 290cbd3..0000000 --- a/preseed/wheezy/commands/late_commands.d/no_kernel_symlinks +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -echo "Removing kernel symlinks in / and disabling them..." -rm /initrd.img /vmlinuz -sed -i -e '/do_symlinks/s/yes/no/' /etc/kernel-img.conf diff --git a/preseed/wheezy/commands/late_commands.d/post_boot_cleanup b/preseed/wheezy/commands/late_commands.d/post_boot_cleanup deleted file mode 100755 index f1fd808..0000000 --- a/preseed/wheezy/commands/late_commands.d/post_boot_cleanup +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh - -SCRIPT=/etc/init.d/post_boot_cleanup -SYMLINK=/etc/rcS.d/S99post_boot_cleanup - -cat >> $SCRIPT <<_eof -#!/bin/sh -sed -i -e '/getty.*tty[12]/s/^#//' /etc/inittab -telinit q -rm $SCRIPT -update-rc.d ${SCRIPT##*/} remove -_eof - -chmod 755 $SCRIPT -update-rc.d ${SCRIPT##*/} start S 99 . diff --git a/preseed/wheezy/commands/late_commands.d/srv-home_symlink b/preseed/wheezy/commands/late_commands.d/srv-home_symlink deleted file mode 100755 index 56911e7..0000000 --- a/preseed/wheezy/commands/late_commands.d/srv-home_symlink +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh -echo "Making /home a bind-mount of /srv/home..." -mkdir -m755 /srv/home -cat >>/etc/fstab <<_eof -/srv/home /home auto defaults,bind 0 0 -_eof -mount --bind /srv/home /home diff --git a/preseed/wheezy/preseed.cfg b/preseed/wheezy/preseed.cfg deleted file mode 100644 index a020f23..0000000 --- a/preseed/wheezy/preseed.cfg +++ /dev/null @@ -1,133 +0,0 @@ -d-i debian-installer/locale string en_NZ - -d-i keyboard-configuration/xkb-keymap select us -d-i keyboard-configuration/layoutcode string us - -d-i netcfg/choose_interface select auto -d-i netcfg/dhcp_options select Configure network manually -d-i netcfg/confirm_static boolean true -d-i netcfg/wireless_wep string - -d-i hw-detect/load_firmware boolean true - -d-i mirror/country string manual -d-i mirror/protocol string http -d-i mirror/http/hostname string http.debian.net -d-i mirror/http/directory string /debian -d-i mirror/http/proxy string -d-i mirror/suite string wheezy - -d-i anna/choose_modules string network-console -d-i network-console/password password r00tme -d-i network-console/password-again password r00tme -d-i network-console/start boolean true -d-i di-utils-shell/do-shell boolean true - -d-i passwd/make-user boolean false -d-i passwd/root-password-crypted password $6$lifGZQZ9$OVYc/Z26ilx1DLCOyPSy1/xOz5o.f6weCgMHYXQZ9EE38DYt0xJBd1Z83/KMWhDyeNmKxp0TUqpJN6w.MT72// - -d-i time/zone string Europe/Berlin - -d-i clock-setup/utc boolean true -d-i clock-setup/ntp boolean true - -d-i partman-basicfilesystems/choose_label string gpt -d-i partman-basicfilesystems/default_label string gpt -d-i partman-partitioning/choose_label string gpt -d-i partman-partitioning/default_label string gpt -d-i partman/choose_label string gpt -d-i partman/default_label string gpt - -#d-i partman-partitioning/confirm_write_new_label boolean true -#d-i partman-partitioning/unknown_label boolean true - -d-i partman-auto/disk string /dev/vda -d-i partman-auto/method string lvm -d-i partman-auto/purge_lvm_from_device boolean true - -d-i partman-auto/expert_recipe string madduck :: \ - 1 1 1 free \ - $gptonly{ } \ - $primary{ } \ - method{ biosgrub } \ - . \ - 8192 32768 -1 ext3 \ - $defaultignore{ } \ - $primary{ } \ - method{ lvm } \ - . \ - 128 1024 200% linux-swap \ - $lvmok{ } lv_name{ swap } \ - method{ swap } format{ } \ - . \ - 1024 1536 3072 ext3 \ - $lvmok{ } lv_name{ root } \ - method{ format } format{ } \ - use_filesystem{ } filesystem{ ext4 } \ - mountpoint{ / } label{ root } \ - options/relatime{ relatime } \ - options/user_xattr{ user_xattr } \ - . \ - 2048 3072 6144 ext3 \ - $lvmok{ } lv_name{ usr } \ - method{ format } format{ } \ - use_filesystem{ } filesystem{ ext4 } \ - mountpoint{ /usr } label{ usr } \ - options/noatime{ noatime } \ - options/nodev{ nodev } \ - . \ - 2048 4096 8192 ext3 \ - $lvmok{ } lv_name{ var } \ - method{ format } format{ } \ - use_filesystem{ } filesystem{ ext4 } \ - mountpoint{ /var } label{ var } \ - options/relatime{ relatime } \ - . \ - 512 10240 -1 ext3 \ - $lvmok{ } lv_name{ srv } \ - method{ format } format{ } \ - use_filesystem{ } filesystem{ ext4 } \ - mountpoint{ /srv } label{ srv } \ - options/nodev{ nodev } \ - options/relatime{ relatime } \ - options/user_xattr{ user_xattr } \ - . \ - 512 768 1024 ext3 \ - $lvmok{ } lv_name{ tmp } \ - method{ format } format{ } \ - use_filesystem{ } filesystem{ ext4 } \ - mountpoint{ /tmp } label{ tmp } \ - options/nodev{ nodev } \ - options/relatime{ relatime } \ - options/user_xattr{ user_xattr } \ - . -d-i partman-auto/choose_recipe select madduck -d-i partman-auto-lvm/no_boot boolean true - -d-i partman-md/device_remove_md boolean true -d-i partman-lvm/device_remove_lvm boolean true -d-i partman-lvm/confirm boolean true -d-i partman-lvm/confirm_nooverwrite boolean true - -d-i partman/choose_partition select finish -d-i partman/confirm boolean true -d-i partman/confirm_nooverwrite boolean true - -d-i apt-setup/non-free boolean false -d-i apt-setup/contrib boolean false - -popularity-contest popularity-contest/participate boolean false - -tasksel tasksel/first multiselect - -#d-i pkgsel/include string openssh-server libterm-readline-gnu-perl - -d-i grub-installer/only_debian boolean true - -d-i finish-install/reboot_in_progress note - -d-i debian-installer/exit/poweroff boolean false -d-i debian-installer/exit/halt boolean false - -d-i preseed/early_command string tar -xf /commands.tar && rm /commands.tar && [ ! -x /commands/early_command ] || log-output -t early_command /commands/early_command -d-i preseed/late_command string [ ! -x /commands/late_command ] || log-output -t late_command /commands/late_command diff --git a/vinst b/vinst index 9775cbb..ca6015a 100755 --- a/vinst +++ b/vinst @@ -8,7 +8,7 @@ DISK=20 CPUS=1 STORAGE_POOL=default QEMU_URI=qemu:///system -SUITE=wheezy +SUITE=stretch CONSOLE='console=tty0 console=ttyS0,115200n8' DEBUG=0 WIPE=0 -- 2.39.5