问题描述
我在使Rails自动测试通知无法在Engine Yard Vagrant环境上工作时遇到麻烦.在Mac上,我通常会通过Growl收到通知.但是,在虚拟环境(运行Ubuntu)上无法正常工作.
I am having trouble getting Rails autotest notifications to work on the Engine Yard Vagrant environment. On the Mac, I normally get the notifications via Growl. However, on the virtual environment (which runs Ubuntu) that doesn't work.
我尝试运行Linux通知设置,例如libnotify + autotest-notification,但是出现以下错误:
I tried running Linux notification setups such as libnotify+autotest-notification, but I get the following error:
libnotify-Message: Unable to get session bus: /bin/dbus-launch terminated abnormally with the following error: Autolaunch error: X11 initialization failed.
** (notify-send:1004): CRITICAL **: dbus_g_proxy_connect_signal: assertion `DBUS_IS_G_PROXY (proxy)' failed
** (notify-send:1004): CRITICAL **: dbus_g_proxy_connect_signal: assertion `DBUS_IS_G_PROXY (proxy)' failed
** (notify-send:1004): CRITICAL **: dbus_g_proxy_call: assertion `DBUS_IS_G_PROXY (proxy)' failed
另一种方法是让Growl远程接收通知,但我什至不知道从哪里开始...
Another path would be to have Growl receive the notifications remotely, but I don't even know where to begin with that...
有什么建议吗?
推荐答案
Web服务器将无法访问桌面以进行通知.出于安全原因,这通常是一件好事.
The web server won't have access to the desktop for notifications. This is generally a good thing, for security reasons.
在Growl安装程序dmg
中是程序growlnotify
,可以将其调整为在大多数Posix-ish系统上构建的程序,并可以发送远程通知.您还必须将Growl配置为接收远程通知(系统配置>其他> Growl>网络).
In the Growl installer dmg
is a program growlnotify
, which can be tweaked into building on most Posix-ish systems and can send remote notifications. You will also have to configure Growl to receive remote notifications (System Prefeences > Other > Growl > Network).
这篇关于在Ubuntu虚拟环境上自动测试通知的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!