Browse Source

no message

master
Brielle Bruns 1 year ago
parent
commit
daa8634170
3 changed files with 16 additions and 6 deletions
  1. +0
    -1
      meta-data
  2. +14
    -3
      user-data
  3. +2
    -2
      virt-install-cloud.sh

+ 0
- 1
meta-data View File

@@ -1,5 +1,4 @@
instance-id: iid-%GUEST_NAME%;
hostname: %GUEST_NAME%
local-hostname: %GUEST_NAME%
manage_resolv_conf: true
dsmode: local

+ 14
- 3
user-data View File

@@ -11,13 +11,24 @@ users:

ssh_pwauth: True
package_upgrade: true

apt_upgrade: false
#manage_etc_hosts: localhost
manage_etc_hosts: true

fqdn: %FQDN%

timezone: US/Mountain
datasource_list:
- ConfigDrive

manage_resolv_conf: true
resolv_conf:
nameservers: ['%NAMESERVER1%', '%NAMESERVER2%']
searchdomains:
- %DOMAIN%
domain: %DOMAIN%

#datasource_list:
# - ConfigDrive

packages:
- openssh-server


+ 2
- 2
virt-install-cloud.sh View File

@@ -118,7 +118,7 @@ arch="amd64"
source distros

sed -e "s/%GUEST_NAME%/${hostname}/" ${WORKING_DIR}/meta-data > ${WORKING_DIR}/output/meta-data
sed -e "s/%FQDN%/${hostname}.${domain}/" ${WORKING_DIR}/user-data > ${WORKING_DIR}/output/user-data
sed -e "s/%FQDN%/${hostname}.${domain}/" -e "s/%DOMAIN%/${domain}/" -e "s/%NAMESERVER1%/${nameserver1}/" -e "s/%NAMESERVER2%/${nameserver2}/" ${WORKING_DIR}/user-data > ${WORKING_DIR}/output/user-data

if [[ ${virt_netinfo_type} == "eni" ]]; then
cat ${WORKING_DIR}/network/legacy-eni >> ${WORKING_DIR}/output/meta-data
@@ -230,6 +230,6 @@ virt-install \
sleep 5

virsh change-media ${hostname}.${domain} vdb --eject --config
# cleanup
rm configuration.iso output/meta-data output/user-data output/network-config

Loading…
Cancel
Save