Márius Rak
Márius Rak

Reputation: 1472

Meteor custom CLI tool

Is it possible to create custom meteor command line tool where mongo and custon JS code of application would be used?

I'd like to have tool inside my web app with which I could perform actions that would be otherwise inaccessible, so I'd have to be connected to the machine where meteor is running e.g. via SSH.

My idea is to run something like meteor customcli myaction arg1 arg2 where customcli would say to meteor engine that it should not start new server, but rather connect to currently running one and myaction would be my custom command with augments following.

If this is not possible directly by meteor. Can I achieve something like that e.g. with node? With standalone node could be problem with babel, since lot of code written in meteor is in version of ES that is currently not natively supported by node, so how could I achieve isomorphism in this?

Thanks.

Upvotes: 0

Views: 48

Answers (1)

rooch84
rooch84

Reputation: 654

Will meteor shell do what you need to do?

https://docs.meteor.com/commandline.html#meteorshell

Upvotes: 0

Related Questions