I’m currently polishing the MariaDB package port and I have a few general questions on the way to improve it :
I’ve noticed that in case of NGinx package, the user/group “nginx” were created : I wasn’t aware that Haiku could create additional users : does it mean that for MariaDB, it could be useful to have a dedicated user/group like “mysql:mysql” ?
For the moment I’ve used the default user “user” which has the root provilege
In case of uninstalling the package, I would like to let the user decide if the mariadb databases (currently in /boot/home/config/var/mariadb/data/) should be cleaned up or not
I guess I have to use the “$preUninstallDir” and write a ksh to do that ?
For the moment no package in Haiku Ports is using this feature, that’s why I’m asking
In case of installation, I will investigate if the current mariadb scripts can be enhanced to allow to enter a username/password for the “root” mariadb user
I will use “$postInstallDir” for that. I know that command like “filedialog” gives the possibility to select a file . Is there any equivalent command to ask for a string or a password from a user ?
Additional point : if there’s no way to ask for a username / password like for filedialog would it make sense to integrate a tool like shanty in Haiku directly ?
Good catch on the example for nginx, I guess that process indeed could be useful to create a user/group mysql:mysql (not to interfere with existing users and a check to make sure the user doesn’t exist).
On the uninstall part, so far there is no feature in pkgman/haikuporter that I know of to uninstall user related/installed directories/files.