Image size optimisations
Added query.php (based on Spotweb's retrieve.php) to use Spotweb's PHP-native database access to pull information about NNTP servers and admin user. No need for the db-specific tools - so removed them.
Removed non-PDO db extensions from PHP (Spotweb only uses PDO).
Removed .git folder after clone.
Fixed usage of apk --no-cache (which implies apk update) so nothing is left behind.
These optimisations reduced the image size for me (ARM64) from 202.5MB to 103.2MB.
I like this solution, however I do run into some (small) problems. On a new clean startup, the query.php script causes some problems (which does not happen on the current master branch). Hope you can have a look at that.
spotweb-1 | Schema update done
spotweb-1 | Updating settings
spotweb-1 | Doing mass upgrade of user settings : date_formatting to "short"
spotweb-1 | Settings update done
spotweb-1 | Updating users
spotweb-1 | Users' update done
spotweb-1 | SpotWeb v0.68.38.34 on PHP v8.3.8 crashed Fatal error occured: Settings needs to be upgraded. #0 /app/lib/Bootstrap.php(69): Bootstrap->validate() #1 /app/query.php(13): Bootstrap->boot() #2 {main}
spotweb-1 | Admin has already logged in, no need to set default password
spotweb-1 | /etc/cont-init.d/40-initialize-db: line 20: [: too many arguments
spotweb-1 | cont-init: info: /etc/cont-init.d/40-initialize-db exited 0
Had a bit of time to look at it, and could use almost everything you added, so thanks a lot for that! The problem with the original set-up was that a clean Spotweb installation failed to start (because the bootstrap->boot would fail). I used a workaround, and this seems to work nicely.
To get it done quickly, I created a new PR and merged it. But again, thanks for your work!