[ec2] add default provisioning script
This commit is contained in:
@@ -22,8 +22,8 @@ rc-update del x-setup boot
|
||||
# Enable ssh
|
||||
rc-update add sshd default
|
||||
|
||||
# setup default root password
|
||||
echo "root:sabayonamichangeme" | chpasswd
|
||||
# delete root password, only ssh allowed
|
||||
passwd -d root
|
||||
|
||||
# setup UTC clock
|
||||
sed -i 's:clock=".*":clock="UTC":' /etc/conf.d/hwclock || exit 1
|
||||
@@ -58,7 +58,6 @@ kernel ${kernel_bin} root=/dev/sda1
|
||||
" > /boot/grub/grub.conf
|
||||
# initrd ${initrd_bin}
|
||||
|
||||
|
||||
# Generate list of installed packages
|
||||
equo query list installed -qv > /etc/sabayon-pkglist
|
||||
|
||||
|
||||
16
scripts/image_remaster_post.sh
Executable file
16
scripts/image_remaster_post.sh
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
|
||||
# execute parent script
|
||||
/sabayon/scripts/remaster_post.sh
|
||||
if [ "${?}" != "0" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Setup provisioning script for Amazon EC2 to load at startup
|
||||
EC2_DIR="/sabayon/remaster/ec2_image"
|
||||
PROV_SCRIPT="ec2.start"
|
||||
cp -p "${EC2_DIR}/${PROV_SCRIPT}" "${CHROOT_DIR}/etc/local.d/" || exit 1
|
||||
chown root:root "${CHROOT_DIR}/etc/local.d/${PROV_SCRIPT}" || exit 1
|
||||
chmod 744 "${CHROOT_DIR}/etc/local.d/${PROV_SCRIPT}" || exit 1
|
||||
|
||||
exit 0
|
||||
Reference in New Issue
Block a user