I have the following case:
我有以下情况:
I want to be able to run an independent Ruby script as a daemon. I would like to be able to execute this script in the context/environment of my Rails project (so that the script can have access to the back-end/my Rails models, for example).
我希望能够作为守护程序运行独立的Ruby脚本。我希望能够在Rails项目的上下文中/环境中执行这个脚本(例如,这样脚本就可以访问后端/我的Rails模型)。
Is there a straightforward way to accomplish this?
有没有一种简单的方法来实现这个目标?
Thanks!
谢谢!