loopback4-microservice-catalog
loopback4-microservice-catalog copied to clipboard
Audit log throws unexpected error on start of the service
Describe the bug Any service using the ARC Audit Service fails at start with the following error when using it after docker prune -
Starting newrelic agent
60
node:internal/modules/cjs/loader:1143
59
throw err;
58
^
57
56
Error: Cannot find module './doc/workbook'
55
Require stack:
54
- /home/node/app/node_modules/exceljs/lib/exceljs.nodejs.js
53
- /home/node/app/node_modules/exceljs/excel.js
52
- /home/node/app/node_modules/@sourceloop/audit-service/dist/services/audit-log-export.service.js
51
To Reproduce Steps to reproduce the behavior:
- install the latest ARC Audit Service
- bind it's component in any Loopback application
- Run node-prune
- Start the service
- See error
Expected behavior The service should start without any error
Additional context
The issue seems to be because of node-prune removing docs named folders from node_modules, and excejs used by the latest audit service seems to be dependent on it