cf-clearance-scraper icon indicating copy to clipboard operation
cf-clearance-scraper copied to clipboard

API Returns 500 Error in Docker Environment but Works Locally

Open HackerinoS2 opened this issue 6 months ago • 10 comments

Description:

I've encountered an issue where the API returns {"code":500,"message":"Request Timeout"} when running within a Docker container. However, the API functions correctly when run directly on my local machine using Node.js.

Steps to Reproduce:

  1. Run the Docker container with:
docker run -d -p 3000:3000 \
-e PORT=3000 \
-e browserLimit=20 \
-e timeOut=30000 \
zfcsoftware/cf-clearance-scraper:latest
  1. Make a request to the API endpoint (e.g., http://localhost:3000/cf-clearance-scraper).

Expected Behavior:

The API should return a successful response as it does when running locally.

Actual Behavior:

The API returns a 500 error with the message: {"code":500,"message":"Request Timeout"}.

Additional Information:

  • Local Environment:
    • Node.js version: v20.16.0
    • Operating System: EndeavourOS (Kernel: 6.6.40-1-lts)
  • Docker Environment:
    • Docker version: 27.0.3

Questions:

  1. Are there any known issues with running this API in Docker?
  2. Could there be specific Docker configurations affecting the API behavior?

Any insights or suggestions would be greatly appreciated!

HackerinoS2 avatar Aug 01 '24 13:08 HackerinoS2