Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error starting exec: Unrecognized input header: 60 #228

Open
morganzero opened this issue Jul 22, 2023 · 1 comment
Open

Error starting exec: Unrecognized input header: 60 #228

morganzero opened this issue Jul 22, 2023 · 1 comment

Comments

@morganzero
Copy link

Hello,

I'm encountering an unexpected error when running scheduled jobs in WHMCS. The initial setup of the scheduler appears to be fine. The log output confirms the successful registration of the jobs:

2023-07-22T21:45:27.903+02:00 scheduler.go:34 ▶ NOTICE New job registered "whmcs-2" - "/usr/local/bin/php -q /opt/whmcs_folders/crons/cron.php" - "@daily"
2023-07-22T21:45:27.904+02:00 scheduler.go:34 ▶ NOTICE New job registered "whmcs-1" - "/usr/local/bin/php -q /opt/whmcs_folders/crons/cron.php" - "@every 5m"
2023-07-22T21:45:27.904+02:00 scheduler.go:54 ▶ DEBUG Starting scheduler with 2 jobs

However, after 5 minutes, an error occurs when the job "whmcs-1" attempts to run:

2023-07-22T21:50:27.005+02:00 common.go:125 ▶ NOTICE [Job "whmcs-1" (0858b34b2be5)] Started - /usr/local/bin/php -q /opt/whmcs_folders/crons/cron.php
2023-07-22T21:50:27.022+02:00 common.go:121 ▶ ERROR [Job "whmcs-1" (0858b34b2be5)] Finished in "17.328679ms", failed: true, skipped: false, error: error starting exec: Unrecognized input header: 60

Here's a snippet from my docker-compose file which outlines the related services:

version: "3.9"
networks:
  sushiweb:
    external: true
services:
  whmcs:
    container_name: whmcs
    image: docker.io/sushibox/dapi:latest
    restart: always
    networks:
      whmcs_network:
        ipv4_address: 172.xx.xx.1
    labels:
      - "ofelia.enabled=true"
      - "ofelia.job-exec.whmcs-1.schedule=@every 5m"
      - "ofelia.job-exec.whmcs-1.command=/usr/local/bin/php -q /opt/whmcs_folders/crons/cron.php"
      - "ofelia.job-exec.whmcs-2.schedule=@daily"
      - "ofelia.job-exec.whmcs-2.command=/usr/local/bin/php -q /opt/whmcs_folders/crons/cron.php"
  whmcs-crons:
    container_name: whmcs-crons
    image: mcuadros/ofelia:latest
    restart: always
    depends_on:
      - whmcs
    networks:
      whmcs_network:
        ipv4_address: 172.xx.xx.2
    environment:
      - DOCKER_HOST=tcp://dockerproxy:2375
      - PUID=${PUID}
      - PGID=${PGID}
      - UMASK=${UMASK}
    command: daemon --docker
    volumes:
      - "/etc/timezone:/etc/timezone:ro"
      - "/etc/localtime:/etc/localtime:ro"

I'm not certain what is causing this issue. Any assistance or guidance would be greatly appreciated.

Please let me know if you need more information or if I've missed any details.

@DnaMes
Copy link

DnaMes commented May 28, 2024

I faced the same issue...

For me it was the Docker Socket Proxy!

I've changed the following environment flag of the docker socket proxy (tecnativa):
EXEC=1

hope it helps!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants