0

I'm starting actionhero by this command

pm2 start .\node_modules\actionhero\bin\actionhero

But actionhero doesn't start successfully and this is in my pm2 log:

error: No config directory found in this project, specified with --config, or found in process.env.ACTIONHERO_CONFIG

leroydev
  • 2,915
  • 17
  • 31
Sifb71
  • 41
  • 10

1 Answers1

1

I have no experience with actionhero but it clearly says no config directory found. Either 1. --config parameter has to be passed as next argument for pm2 start or 2. Set an env variable ACTIONHERO_CONFIG to appropriate value.

Boot Options to find the Config Directory

When launching ActionHero you can specify which config directory to use with --config '/path/to/dir' or the environment variable ACTIONHERO_CONFIG, otherwise ./config/ will be used from your working directory.

The priority of arguments is:

Use the project's ./config folder, if it exists.
actionhero --config=PATH1 --config=PATH2 --config=PATH3,PATH4
ACTIONHERO_CONFIG=PATH1,PATH2 npm start
Note that if --config or ACTIONHERO_CONFIG are used, they overwrite the use of the default /config folder. If you wish to use both, you need to re-specify "config", e.g. --config=config,local-config. Also, note that specifying multiple --config options on the command line does exactly the same thing as using one parameter with comma separators, however the environment variable method only supports the comma-delimited syntax.
PrivateOmega
  • 2,509
  • 1
  • 17
  • 27