[ami_pre] add option to have custom image size (closes #237450) [applied]