Closed inverse closed 6 months ago
Still seems quite big? I guess we could change the base image to be just vanilla alpine?
I think it is fairly OK?
The biggest chunk/layer is 116Mb, which is the official upstream node base images I've started using. (Mostly because I have too, as the shipped NodeJS by Alpine Linux will not build on armv7 due to a QEMU bug).
Looking at pure the add-on itself, it adds 31MB, of which about 6.9MB is for TasmoAdmin (including all assets and vendored libraries), and 24MB is basically the PHP and its dependencies.
What could be done, is building using the NodeJS base image in the first state, copy the www
folder over from the second stage using the generic add-on base image.
This assumes the NodeJS runtime isn't used @ the normal add-on lifetime.
Thanks for explaining! Yeah it sounds like using the node image as the build environment and copying out could be a good solution.
I'm not fully understanding why this one is stuck on armv7
Do you think it could be to do with now using esbuild?
I guess we can use the release artifacts as they include the assets already compiled
Closing this in favour of #389 which should work as the frontend assets will be prebuilt.
Then I guess #383 could be tested and things should just work.
Proposed Changes
The major version bump is because of the frontend buildchain change which now has an
npm build
which takes care of everything.Comes with the added bonus of not needing to include
node_modules
which brings the whole image down in size too!Still seems quite big? I guess we could change the base image to be just vanilla alpine?
Tested by copying into my addon on my local instance and running there and all seems working from testing.
Related Issues