Deploying my express/postgres backend

hey guys I’m trying to deploy express with a postgres database so far I’ve manged to get my express server running and connected to a db however, In my dev environment I would now use a CLI for my ORM too add the tables and initial data how do I go about doing that from a hosting setup.

could I add the CLI as a dependant and then connect via the hosting’s CLI and manually run it just like I do when I create it locally? or could I write a script in the package.json file which will handle this automatically?

lil lost here help pls