I have been working with the ideas from this post: Is it possible to run migrations as a different user? - #5 by hauleth about running migrations as a different user. This is for running on production machine for security reasons we do not wish to allow the app to have permissions to create or modify tables.
Is it possible to build a mix task into an executable? Like escript? Because then we could use OptionParser or similar to read command-line arguments. Or maybe that is too difficult because it would need this separate script to connect to the same PostGres database (but using a different username/password). Maybe it is better to simply prompt the user for input from iex
? Perhaps using something like Cowrie ā cowrie v0.3.0 ?
I hope am explaining this situation clearly. Iām not sure what options are possible.
Thank you