Image Optimization: Add optipng and jpegoptim packages for each container.
-
It was added to the base image which all apps use, not just WordPress. See https://git.cloudron.io/cloudron/docker-base-image/-/commit/feb87a57028b4891be49b3963a70847a74e5425c
-
-
-
Hello,
Image optimization is one of the most important things for the new web. For years now, I have been using these small magic tools on my server, which saves me time and a lot of GBs.Even I am using it at my home devices.
I suggest including it with all apps so I can open the app terminal and run it using the following commands to start optimizing photos at the server level.
nice -n 19 find . -iname '*.jpg' -print0 | xargs -0 jpegoptim --max=82 --all-progressive --strip-all --preserve --totals --force nice -n 19 find . -iname '*.jpeg' -print0 | xargs -0 jpegoptim --max=82 --all-progressive --strip-all --preserve --totals --force nice -n 19 find . -iname '*.png' -print0 | xargs -0 optipng -o7 -preserve
wrote on Dec 13, 2023, 12:23 PM last edited by@BetterWP said in Image Optimization: Add optipng and jpegoptim packages for each container.:
open the app terminal and run it using the following commands to start optimizing photos at the server level.
Can we have a button for those of us who don't want to meddle with commands on the app terminal unless they are really needed, please?!
Do we have to run this command every now and then to optimise images as they are added to the application? If then, can we cron job it?
-
wrote on Dec 13, 2023, 12:32 PM last edited by
Sorry if this is a N00B question, but if we add this at the server level, can't we recursively optimise all images on the server, irrespective of the application?
Like, say:
[Launch] Optimise Images Tool
Select Applications to run image optimisation on
[Checklist of Apps on Server][Start Optimisation]
-
wrote on Feb 19, 2024, 8:03 AM last edited by
I'm also interested in hosting such a service in Cloudron.
Typically, to avoid sending images to 3rd-parties not knowing what they may do with it.
It should be an application, like any other app.
Maybe this app could have a feature that automatically optimize files on the server itself, but indeed it seems like a very specific feature. -
I'm also interested in hosting such a service in Cloudron.
Typically, to avoid sending images to 3rd-parties not knowing what they may do with it.
It should be an application, like any other app.
Maybe this app could have a feature that automatically optimize files on the server itself, but indeed it seems like a very specific feature.wrote on Feb 19, 2024, 8:23 AM last edited by@AmbroiseUnly In the meantime you can use https://shortpixel.com
-
@BetterWP a workaround for now till we update our base image is :
In web terminal:
mkdir -p /app/data/jpegoptim cd /app/data/jpegoptim wget https://github.com/tjko/jpegoptim/releases/download/v1.5.5/jpegoptim-1.5.5-x64-linux.zip unzip jpegoptim-1.5.5-x64-linux.zip chmod +x jpegoptim ./jpegoptim --help