Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ $ eggctl start [options] [baseDir]
- `port` - listening port, default to `process.env.PORT`, if unset, egg will use `7001` as default.
- `title` - process title description, use for kill grep, default to `egg-server-${APP_NAME}`.
- `workers` - numbers of app workers, default to `process.env.EGG_WORKERS`, if unset, egg will use `os.cpus().length` as default.
- `daemon` - whether run at background daemon mode.
- `daemon` - whether run at background daemon mode, don't use it if in docker mode.
- `framework` - specify framework that can be absolute path or npm package, default to auto detect.
- `env` - server env, default to `process.env.EGG_SERVER_ENV`, recommended to keep empty then use framwork default env.
- `stdout` - customize stdout file, default to `$HOME/logs/master-stdout.log`.
Expand All @@ -60,6 +60,8 @@ $ eggctl start [options] [baseDir]

Stop egg gracefull.

**Note:** if exec without `--title`, it will kill all egg process.

```bash
# stop egg
$ eggctl stop [--title=example]
Expand Down
2 changes: 2 additions & 0 deletions lib/cmd/start.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,12 +210,14 @@ class StartCommand extends Command {
if (hasError) {
try {
const [ stdout ] = yield exec('tail -n 100 ' + stderr);
this.logger.error('Got error when startup: ');
this.logger.error(stdout);
} catch (_) {
// nothing
}
isSuccess = ignoreStdErr;
this.logger.error('Start got error, see %s', stderr);
this.logger.error('Or use `--ignore-stderr` to ignore stderr at startup.');
}

if (!isSuccess) {
Expand Down