diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4a02dba5..ab01997d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -128,11 +128,6 @@ jobs: run: | docker run -d \ --name smoke \ - --health-cmd "/bin/bash /ping-check.sh" \ - --health-interval 1s \ - --health-retries 60 \ - --health-timeout 2s \ - --health-start-period 2s \ --rm -p3000:3000 \ ${{ vars.DOCKER_IMAGE }}:${{ matrix.tag }} diff --git a/Dockerfile b/Dockerfile index e0437ff7..746ad623 100644 --- a/Dockerfile +++ b/Dockerfile @@ -200,10 +200,6 @@ ENV WAHA_GOWS_SOCKET /tmp/gows.sock COPY entrypoint.sh /entrypoint.sh -# Add healthcheck script -COPY ping-check.sh /ping-check.sh -RUN chmod +x /ping-check.sh - # Chokidar options to monitor file changes ENV CHOKIDAR_USEPOLLING=1 ENV CHOKIDAR_INTERVAL=5000 diff --git a/docker-compose.yaml b/docker-compose.yaml index e640c220..f646462f 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -7,12 +7,6 @@ services: image: devlikeapro/waha-plus # WAHA Core # image: devlikeapro/waha:latest - healthcheck: - test: ['CMD', '/bin/bash', '/ping-check.sh'] - interval: 60s - timeout: 10s - retries: 3 - start_period: 30s logging: driver: 'json-file' diff --git a/ping-check.sh b/ping-check.sh deleted file mode 100644 index a5bb6a07..00000000 --- a/ping-check.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash - -# Try PORT first, then WHATSAPP_API_PORT, then default to 3000 -PORT=${PORT:-${WHATSAPP_API_PORT:-3000}} - -# Check if HTTPS is enabled -if [[ "${WAHA_HTTPS_ENABLED}" == "true" || "${WAHA_HTTPS_ENABLED}" == "1" ]]; then - PROTOCOL="https" -else - PROTOCOL="http" -fi - -# Execute curl command with SSL verification disabled -curl -f -s -k "${PROTOCOL}://127.0.0.1:${PORT}/ping" || exit 1 diff --git a/tests/smoke/goss.yaml b/tests/smoke/goss.yaml index 930df823..cdbbcb9f 100644 --- a/tests/smoke/goss.yaml +++ b/tests/smoke/goss.yaml @@ -4,12 +4,4 @@ http: allow-insecure: true no-follow-redirects: true timeout: 5000 - body: ['version'] - -command: - docker smoke health: - exec: "docker inspect --format '{{`{{if .State.Health}}{{.State.Health.Status}}{{else}}no healthcheck{{end}}`}}' smoke" - exit-status: 0 - stdout: - - 'healthy' - timeout: 5000 + body: ['version'] \ No newline at end of file