[packer] feat: various update

This commit is contained in:
Simon Cornet 2024-07-16 16:53:22 +02:00
parent e77b7086c2
commit 6115fea548
3 changed files with 6 additions and 4 deletions

View File

@ -98,6 +98,7 @@ source "proxmox-iso" "template" {
format = "${var.proxmox_storage_format}" format = "${var.proxmox_storage_format}"
storage_pool = "${var.proxmox_storage_pool}" storage_pool = "${var.proxmox_storage_pool}"
type = "virtio" type = "virtio"
cache_mode = "unsafe"
} }
# networking # networking

View File

@ -2,9 +2,9 @@
# update the guest # update the guest
echo '> Updating the guest ...' echo '> Updating the guest ...'
sudo -u root apt update sudo -u root apt-get update
sudo -u root DEBIAN_FRONTEND=noninteractive apt -y upgrade sudo -u root DEBIAN_FRONTEND=noninteractive apt-get -y upgrade
sudo -u root apt autoremove -y sudo -u root apt-get autoremove -y
# install rc.local script # install rc.local script
cat << 'EOL' | sudo tee /etc/rc.local cat << 'EOL' | sudo tee /etc/rc.local
@ -53,7 +53,7 @@ sudo -u root hostnamectl set-hostname localhost
# cleans apt. # cleans apt.
echo '> cleaning apt-get ...' echo '> cleaning apt-get ...'
sudo -u root apt clean sudo -u root apt-get clean
# cleans the machine-id # cleans the machine-id
echo '> cleaning the machine-id ...' echo '> cleaning the machine-id ...'

View File

@ -98,6 +98,7 @@ source "proxmox-iso" "template" {
format = "${var.proxmox_storage_format}" format = "${var.proxmox_storage_format}"
storage_pool = "${var.proxmox_storage_pool}" storage_pool = "${var.proxmox_storage_pool}"
type = "virtio" type = "virtio"
cache_mode = "unsafe"
} }
# networking # networking