diff --git a/package-lock.json b/package-lock.json index 0d59302..103ec84 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,7 +16,8 @@ "express": "^5.1.0", "express-rate-limit": "^7.5.0", "pino": "^9.7.0", - "pino-pretty": "^13.0.0" + "pino-pretty": "^13.0.0", + "typescript": "^5.8.3" }, "devDependencies": { "@babel/core": "^7.27.3", @@ -38,8 +39,7 @@ "prettier": "^3.0.0", "supertest": "^7.1.1", "ts-jest": "^29.3.4", - "ts-node": "^10.9.2", - "typescript": "^5.8.3" + "ts-node": "^10.9.2" }, "engines": { "node": ">=20.0.0" @@ -10884,7 +10884,6 @@ "version": "5.8.3", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", - "dev": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" diff --git a/package.json b/package.json index 8e316ef..9a8256b 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,8 @@ "express": "^5.1.0", "express-rate-limit": "^7.5.0", "pino": "^9.7.0", - "pino-pretty": "^13.0.0" + "pino-pretty": "^13.0.0", + "typescript": "^5.8.3" }, "devDependencies": { "@babel/core": "^7.27.3", @@ -58,8 +59,7 @@ "prettier": "^3.0.0", "supertest": "^7.1.1", "ts-jest": "^29.3.4", - "ts-node": "^10.9.2", - "typescript": "^5.8.3" + "ts-node": "^10.9.2" }, "engines": { "node": ">=20.0.0" diff --git a/run-claudecode-interactive.sh b/run-claudecode-interactive.sh new file mode 100755 index 0000000..ce1447a --- /dev/null +++ b/run-claudecode-interactive.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +# Run claudecode container interactively for testing and debugging +docker run -it --rm \ + -v $(pwd):/workspace \ + -v ~/.aws:/root/.aws:ro \ + -v ~/.claude:/root/.claude \ + -w /workspace \ + --entrypoint /bin/bash \ + claudecode:latest \ No newline at end of file diff --git a/scripts/runtime/startup.sh b/scripts/runtime/startup.sh index a55de4a..72d1f95 100755 --- a/scripts/runtime/startup.sh +++ b/scripts/runtime/startup.sh @@ -10,6 +10,16 @@ else echo "Warning: Failed to build Claude Code runner image. Service will attempt to build on first use." fi +# Ensure dependencies are installed (in case volume mount affected node_modules) +if [ ! -d "node_modules" ] || [ ! -f "node_modules/.bin/tsc" ]; then + echo "Installing dependencies..." + npm ci +fi + +# Always compile TypeScript to ensure we have the latest compiled source +echo "Compiling TypeScript..." +npm run build + # Start the webhook service echo "Starting webhook service..." -exec node src/index.js \ No newline at end of file +exec node dist/index.js \ No newline at end of file