Merge pull request #131 from stefanha/initrd-builder-idempotency

initrd-builder: make initrd_builder.sh idempotent
This commit is contained in:
Jose Carlos Venegas Munoz
2018-07-04 10:54:37 -05:00
committed by GitHub

View File

@@ -73,7 +73,7 @@ OK "Agent is installed"
[ "$(id -u)" -eq 0 ] || die "$0: must be run as root"
# initramfs expects /init
mv -f ${init} "${ROOTFS}/init"
ln -sf /sbin/init "${ROOTFS}/init"
info "Creating ${IMAGE_DIR}/${IMAGE_NAME} based on rootfs at ${ROOTFS}"
( cd "${ROOTFS}" && find . | cpio -H newc -o | gzip -9 ) > "${IMAGE_DIR}"/"${IMAGE_NAME}"