aboutsummaryrefslogtreecommitdiffstats
path: root/stage2
diff options
context:
space:
mode:
authorSerge Schneider <[email protected]>2017-07-11 16:26:52 +0100
committerSerge Schneider <[email protected]>2017-07-28 13:35:46 +0100
commit207003b5edfa33795a9886a5cb434b5079c9817b (patch)
tree0af4f14a09ce0a747a7cd70d77049c128b80a116 /stage2
parentc77669ad9fa11907c623e69a5cb0a5e55001b2b3 (diff)
stage2: Move ssh host key regen and NOOBS config scripts to raspberrypi-sys-mods
Diffstat (limited to 'stage2')
-rwxr-xr-xstage2/01-sys-tweaks/01-run.sh2
-rw-r--r--stage2/01-sys-tweaks/files/apply_noobs_os_config31
-rw-r--r--stage2/01-sys-tweaks/files/regenerate_ssh_host_keys.service11
3 files changed, 0 insertions, 44 deletions
diff --git a/stage2/01-sys-tweaks/01-run.sh b/stage2/01-sys-tweaks/01-run.sh
index e92ceff..f24d529 100755
--- a/stage2/01-sys-tweaks/01-run.sh
+++ b/stage2/01-sys-tweaks/01-run.sh
@@ -1,7 +1,5 @@
#!/bin/bash -e
-install -m 644 files/regenerate_ssh_host_keys.service ${ROOTFS_DIR}/lib/systemd/system/
-install -m 755 files/apply_noobs_os_config ${ROOTFS_DIR}/etc/init.d/
install -m 755 files/resize2fs_once ${ROOTFS_DIR}/etc/init.d/
install -d ${ROOTFS_DIR}/etc/systemd/system/rc-local.service.d
diff --git a/stage2/01-sys-tweaks/files/apply_noobs_os_config b/stage2/01-sys-tweaks/files/apply_noobs_os_config
deleted file mode 100644
index c9afe7d..0000000
--- a/stage2/01-sys-tweaks/files/apply_noobs_os_config
+++ /dev/null
@@ -1,31 +0,0 @@
-#!/bin/sh
-### BEGIN INIT INFO
-# Provides: apply_noobs_os_config
-# Required-Start:
-# Required-Stop:
-# Default-Start: 2
-# Default-Stop:
-# Short-Description: Apply config from /boot/os_config.json
-# Description:
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-set -e
-
-case "$1" in
- start)
- log_daemon_msg "Applying config from /boot/os_config.json (if it exists)"
- if raspi-config --apply-os-config; then
- update-rc.d apply_noobs_os_config remove
- rm /etc/init.d/apply_noobs_os_config
- log_end_msg 0
- else
- log_end_msg 1
- fi
- ;;
- *)
- echo "Usage: $0 start" >&2
- exit 3
- ;;
-esac
diff --git a/stage2/01-sys-tweaks/files/regenerate_ssh_host_keys.service b/stage2/01-sys-tweaks/files/regenerate_ssh_host_keys.service
deleted file mode 100644
index a2d1571..0000000
--- a/stage2/01-sys-tweaks/files/regenerate_ssh_host_keys.service
+++ /dev/null
@@ -1,11 +0,0 @@
-[Unit]
-Description=Regenerate SSH host keys
-
-[Service]
-Type=oneshot
-ExecStartPre=/bin/sh -c "if [ -e /dev/hwrng ]; then dd if=/dev/hwrng of=/dev/urandom count=1 bs=4096; fi"
-ExecStart=/usr/bin/ssh-keygen -A
-ExecStartPost=/bin/rm /lib/systemd/system/regenerate_ssh_host_keys.service ; /usr/sbin/update-rc.d regenerate_ssh_host_keys remove
-
-[Install]
-WantedBy=multi-user.target