diff options
author | Alex Yang <yangyang1@zte.com.cn> | 2017-12-19 10:30:41 +0800 |
---|---|---|
committer | Alex Yang <yangyang1@zte.com.cn> | 2017-12-22 14:38:49 +0800 |
commit | 340b49d75690ccdb3f36378c3e20e8e5c13a212a (patch) | |
tree | f9e965c86abbb2abb8b856bece29b8bc5e06bae6 /tools | |
parent | 27cb947c971bda2ee6ee39345250580ff75f7d7e (diff) |
Generate .ssh/known_hosts when making VM image
Change-Id: I3f72239d6c4db27f67d5586c45e46ed01fad281d
Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/centos-img-modify.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/centos-img-modify.sh b/tools/centos-img-modify.sh index 31f122fb..c095be73 100755 --- a/tools/centos-img-modify.sh +++ b/tools/centos-img-modify.sh @@ -58,6 +58,12 @@ host_name=daisy echo ${host_name} > /etc/hostname sed -i "/^127.0.0.1/s/ localhost / ${host_name} localhost /g" /etc/hosts +# required by daisycloud-core daisy/api/backends/osinstall/pxe/install.py +# This can be removed when upstream fix it. +mkdir -p -m 700 /root/.ssh +touch /root/.ssh/known_hosts +chmod 600 /root/.ssh/known_hosts + # Allow console access via pwd cat << EOF > /etc/cloud/cloud.cfg.d/default.cfg disable_root: False |