Automate initial user creation

Summary
I need to automate initial user creation remotely with a kubernetes (helm) installation.

Steps to reproduce
Deploy mattermost, try to configure.

Expected behavior
Other enterprise software create an initial admin user automatically and store their credentials in a kubernetes secret. Those credentials are then able to be used to configure the rest of the software (i.e. create teams/permission schemes).

Observed behavior
I was asked to create a user on the mattermost domain.


Reading the documentation, it says to use mmctl, but mmctl needs credentials to run remotely. Therefore mattermost is forcing a human into the software deployment loop. While running mmctl could be exec’d on the pod/container, that is not a declarative configuration process.