You need to write a preseed configuration that is described in Debian / Ubuntu documentations, this is not something iVentoy will cover.
https://wiki.debian.org/DebianInstaller/Preseed
https://wiki.debian.org/AutomatedInstallation
https://ubuntu.com/server/docs/install/autoinstall
https://developer.hashicorp.com/packer/g...eed_ubuntu
https://wiki.debian.org/DebianInstaller/Preseed
https://wiki.debian.org/AutomatedInstallation
https://ubuntu.com/server/docs/install/autoinstall
https://developer.hashicorp.com/packer/g...eed_ubuntu