Batch JPG/PNG Image Compression and Optimization via SSH

This setup will compress all JPG and PNG images in below directories automatically. /public_html/product_images/ /public_html/images/ /public_html/templates/ Prerequisite Make sure below 2 packages are available in your server: jpegoptim optipng Implementation Create file img-opt.sh under cPanel account directory Add the following bash script to the file and save the file, where accname variable should be changed…