When I run phantomJS with crontab, the following errors occur. How can I run it successfully? I am using Ubuntu 17.10.
[error]
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-mizu'
QXcbConnection: Could not connect to display
PhantomJS has crashed. Please read the bug reporting guide at
<http://phantomjs.org/bug-reporting.html> and file a bug report.
Aborted (core dumped)
[crontab]
*/1 * * * * /home/mizu/phantomjs /home/mizu/script.js