Ghost-CLI: command "ghost restart" doesn't work

This issue is a

Bug Report

Summary

My VPS was rebooted by its supplier, and then I wanted to restart my ghost services.However, the command “ghost restart” doesn’t work.

I have tried reinstall ghost-cli, but the error still existed.

Steps to Reproduce (for a bug report)

ghost restart

Technical details (will be automatically output by Ghost-CLI if an error occurs):

  • OS: CentOS 7
  • Node Version:6.11.2
  • Ghost-CLI Version: 1.4.1
  • Environment: production
  • Command: ghost restart

Here are the error log:

Debug Information:
    Node Version: v6.11.2
    Ghost-CLI Version: 1.4.1
    Environment: production
    Command: 'ghost restart'
An error occurred.
Message: 'failed
'

Stack: Error: failed

    at module.exports.sync (/usr/lib/node_modules/ghost-cli/node_modules/_execa@0.8.0@execa/index.js:303:26)
    at handleShell (/usr/lib/node_modules/ghost-cli/node_modules/_execa@0.8.0@execa/index.js:105:9)
    at Function.module.exports.shellSync (/usr/lib/node_modules/ghost-cli/node_modules/_execa@0.8.0@execa/index.js:312:43)
    at SystemdProcessManager.isRunning (/usr/lib/node_modules/ghost-cli/extensions/systemd/systemd.js:61:19)
    at Instance.running (/usr/lib/node_modules/ghost-cli/lib/instance.js:119:27)
    at RestartCommand.run (/usr/lib/node_modules/ghost-cli/lib/commands/restart.js:8:23)
    at precheck.then (/usr/lib/node_modules/ghost-cli/lib/command.js:206:52)
    at process._tickCallback (internal/process/next_tick.js:109:7)
    at Module.runMain (module.js:606:11)
    at run (bootstrap_node.js:389:7)
    at startup (bootstrap_node.js:149:9)
    at bootstrap_node.js:504:3

Kate Note Relies on better logging for systemd (issue TBD). We first need to improve logging to figure out what’s going on.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 16 (7 by maintainers)

Most upvoted comments

@jochenkirstaetter We very much welcome any support or contributions in terms of debugging other stacks or determining minor changes that might have caused issues with other stacks. The CLI team is not able to provide support for problems happening outside the recommended stack at present and we’ve recently updated our readme to reflect this.

The documentation does clearly state to only use /var/www/ in the install guide: https://docs.ghost.org/docs/install#section-create-a-new-folder. If there are other locations in the docs where you think this information should be included, please use the suggest edits button & we’ll add your suggestions.

@AileenCGN one thing we can track as a potential change is to add a location check to ghost doctor so that the install warns when it’s inside a user folder. Currently it only checks permissions of the current folder.

Duplicate of #461 (it also contains temporary workaround info)