[BUG] taiga-events_1 container failing
taiga-events_1 container fails with error:
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start:production: NODE_ENV=production node ./src/index.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start:production script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /taiga-events/.npm/_logs/2021-10-02T13_47_35_746Z-debug.log
Complete log file content:
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli '/usr/local/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'run',
1 verbose cli 'start:production'
1 verbose cli ]
2 info using [email protected]
3 info using [email protected]
4 verbose config Skipping project config: /taiga-events/.npmrc. (matches userconfig)
5 verbose run-script [ 'prestart:production', 'start:production', 'poststart:production' ]
6 info lifecycle [email protected]~prestart:production: [email protected]
7 info lifecycle [email protected]~start:production: [email protected]
8 verbose lifecycle [email protected]~start:production: unsafe-perm in lifecycle true
9 verbose lifecycle [email protected]~start:production: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/taiga-events/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
10 verbose lifecycle [email protected]~start:production: CWD: /taiga-events
11 silly lifecycle [email protected]~start:production: Args: [ '-c', 'NODE_ENV=production node ./src/index.js' ]
12 silly lifecycle [email protected]~start:production: Returned: code: 1 signal: null
13 info lifecycle [email protected]~start:production: Failed to exec start:production script
14 verbose stack Error: [email protected] start:production: NODE_ENV=production node ./src/index.js
14 verbose stack Exit status 1
14 verbose stack at EventEmitter.NODE_ENV=production node ./src/index.js
23 error Exit status 1
24 error Failed at the [email protected] start:production script.
24 error This is probably not a problem with npm. There is likely additional logging output above.
25 verbose exit [ 1, true ]
Had the same symptom, rolling back to taiga-events:6.3.0 to see if it occurs again
Hi! Rolling back to taiga-events:6.3.0 works?
I have the same problem but I start the service manually after taiga-events-rabbitmq is fully up and running. I am waiting for updates
Yes, sometimes the problem with taiga-events is because taiga-events-rabbitmq start after taiga-events. In these cases, simply restart the taiga-events service with docker-compose start -d taiga-events and check the logs again.
The pull request above https://github.com/kaleidos-ventures/taiga-docker/pull/105 fixes this problem.
As a temporary workaround while the pull request is reviewed and (maybe) accepted, you can: In the taiga-events service add:
taiga-events:
...
depends_on:
taiga-events-rabbitmq:
condition: service_healthy
And in the service taiga-events-rabbitmq add:
taiga-events-rabbitmq:
...
healthcheck:
test: "rabbitmq-diagnostics is_running"
This will also slow down the docker compose up, which will now take about 30 seconds to complete (since it will wait for the rabbitmq to be healthy to launch all the remaining pods).
Whoops, as I was reviewing the conflicts on the pull request, I noticed daniel-herrero pushed a fix for this exact issue 4 days ago https://github.com/kaleidos-ventures/taiga-docker/commit/e6af1448b4a7ba4a5e22785ab507500cf38b45e6 . Therefore the pull request above is no more needed, this issue can be closed.
Current stable just has:
taiga-events: ... depends_on: taiga-events-rabbitmq: condition: service_healthy
But error still occurs as per the above. Adding in:
taiga-events-rabbitmq: ... healthcheck: test: "rabbitmq-diagnostics is_running"
Seems to make it work and stops crash