00d9a9d396
Right now this removes the ssh keys on the build host. Obviously this is not what we want. Change-Id: Ib01d71ff9415a0ae04d963f6e380aab9ac2260ce
19 lines
397 B
Bash
Executable File
19 lines
397 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
|
|
set -x
|
|
fi
|
|
set -eu
|
|
set -o pipefail
|
|
|
|
# Cloud images shouldn't have ssh host keys baked
|
|
# in so that they are regenerated on first boot and
|
|
# are unique.
|
|
|
|
# TODO(greghaynes) This should be a thing we do for all images, not just
|
|
# simple-init.
|
|
|
|
if [ -d /etc/ssh ] ; then
|
|
sudo find $TARGET_ROOT/etc/ssh -name 'ssh_host*' -type f -delete
|
|
fi
|