webapp container hangs on startup with no error message #646

Closed
opened 2023-11-14 15:26:08 +00:00 by dboreham · 1 comment
Owner

If something goes wrong in /scripts/start-serving-app.sh it seems that the script can hang forever with no error output to any log that could be fed back to the user/admin.

In the case I found, it looks like:

root@7396c0856834:/app# ps -ef
UID        PID  PPID  C STIME TTY          TIME CMD
root         1     0  0 14:56 ?        00:00:00 bash /scripts/start-serving-app.sh
root       639     1  0 14:56 ?        00:00:00 tail -n0 -f gen.out
root       640     1  0 14:56 ?        00:00:00 sed /rendered as static HTML/ q
root      1007     0  0 14:58 pts/0    00:00:00 bash
root      1014  1007  0 14:59 pts/0    00:00:00 ps -ef

and:

# cat gen.out

> igloo-home@0.1.0 cerc_generate
> next experimental-generate

- info Linting and checking validity of types...
- info Collecting page data...
unhandledRejection /app/.next/server/chunks/535.js:428
const ALCHEMY_GOERLI_API_KEY = ""aomycOzhlRfNZEtNlZZoE0FAwbYMdlZ5"";
                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

SyntaxError: Unexpected identifier 'aomycOzhlRfNZEtNlZZoE0FAwbYMdlZ5'
    at internalCompileFunction (node:internal/vm:73:18)
    at wrapSafe (node:internal/modules/cjs/loader:1153:20)
    at Module._compile (node:internal/modules/cjs/loader:1205:27)
    at Module._extensions..js (node:internal/modules/cjs/loader:1295:10)
    at Module.load (node:internal/modules/cjs/loader:1091:32)
    at Module._load (node:internal/modules/cjs/loader:938:12)
    at Module.require (node:internal/modules/cjs/loader:1115:19)
    at require (node:internal/modules/helpers:130:18)
    at __webpack_require__.f.require (/app/.next/server/webpack-runtime.js:212:28)
    at /app/.next/server/webpack-runtime.js:139:40 {
  type: 'SyntaxError'
}

But that error log output is not sent to stdout for the container.

If something goes wrong in `/scripts/start-serving-app.sh` it seems that the script can hang forever with no error output to any log that could be fed back to the user/admin. In the case I found, it looks like: ``` root@7396c0856834:/app# ps -ef UID PID PPID C STIME TTY TIME CMD root 1 0 0 14:56 ? 00:00:00 bash /scripts/start-serving-app.sh root 639 1 0 14:56 ? 00:00:00 tail -n0 -f gen.out root 640 1 0 14:56 ? 00:00:00 sed /rendered as static HTML/ q root 1007 0 0 14:58 pts/0 00:00:00 bash root 1014 1007 0 14:59 pts/0 00:00:00 ps -ef ``` and: ``` # cat gen.out > igloo-home@0.1.0 cerc_generate > next experimental-generate - info Linting and checking validity of types... - info Collecting page data... unhandledRejection /app/.next/server/chunks/535.js:428 const ALCHEMY_GOERLI_API_KEY = ""aomycOzhlRfNZEtNlZZoE0FAwbYMdlZ5""; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Unexpected identifier 'aomycOzhlRfNZEtNlZZoE0FAwbYMdlZ5' at internalCompileFunction (node:internal/vm:73:18) at wrapSafe (node:internal/modules/cjs/loader:1153:20) at Module._compile (node:internal/modules/cjs/loader:1205:27) at Module._extensions..js (node:internal/modules/cjs/loader:1295:10) at Module.load (node:internal/modules/cjs/loader:1091:32) at Module._load (node:internal/modules/cjs/loader:938:12) at Module.require (node:internal/modules/cjs/loader:1115:19) at require (node:internal/modules/helpers:130:18) at __webpack_require__.f.require (/app/.next/server/webpack-runtime.js:212:28) at /app/.next/server/webpack-runtime.js:139:40 { type: 'SyntaxError' } ``` But that error log output is not sent to stdout for the container.
Author
Owner

To reproduce this, run the iglootools container supplying the standard .env file without editing to remove quotes.

To reproduce this, run the iglootools container supplying the standard .env file without editing to remove quotes.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: cerc-io/stack-orchestrator#646
No description provided.