A Lab deployed using terraform
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

43 lines
1.3 KiB

# Accept the VMware License agreement
accepteula
# Clear all partitions in first detected disk and overwrite any VMFS partition
clearpart --firstdisk --overwritevmfs
# New installation on first disk and overwrite an existing VMFS datastore
install --firstdisk --overwritevmfs
# French keyboard
keyboard French
# Root password. Generated using "openssl passwd -1"
rootpw --iscrypted $1$7McSxAUG$3mAxHfGio8pRT1qHyKQTG. # P@ssw0rd!
# Use DHCP for the first NIC
network --bootproto=dhcp --device=vmnic0
# Reboot after installation
reboot --noeject
# Register vCenter License
#serialnum --esx=XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
# Specifies script to run after ESXi is installed on first boot
%firstboot --interpreter=busybox
# Enable TSM & SSH
vim-cmd hostsvc/enable_ssh
vim-cmd hostsvc/start_ssh
vim-cmd hostsvc/enable_esx_shell
vim-cmd hostsvc/start_esx_shell
# Suppress Shell Warning in Host
esxcli system settings advanced set -o /UserVars/SuppressShellWarning -i 1
# inject SSH authorized keys
echo "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPR1tt58X0+vbvsCR12gMAqr+g7vjt1Fx/qqz9EiboIs nicolas.masse@itix.fr" >> /etc/ssh/keys-root/authorized_keys
echo "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFW62WJXI1ZCMfNA4w0dMpL0fsldhbEfULNGIUB0nQui nmasse@redhat.com" >> /etc/ssh/keys-root/authorized_keys
# Enable NTP
esxcli system ntp set -s pool.ntp.org
esxcli system ntp set -e 1