Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Healthcheck issue#7132

Unanswered
lordlightman asked this question inGeneral
Dec 19, 2024· 1 comments· 1 reply
Discussion options

Hello.

I am experiencing a weird issue with healthcheck that prevents Code Server from working properly. Whenever I'm using an expression like this as a test

curl -fksSL http://localhost:8443/healthz | grep -o alive || exit 1

Code Server does not work - Web UI is not accessible, andhealthz endpoint reportsexpired.

But when I use['CMD', 'curl', '-fksSL', 'http://localhost:8443/healthz'] everything works fine, Code Server starts and within 10-20 secondshealthz reports 'alive'.

Does anyone know what could be the issue? Am I doing something wrong?

Here is my fulldocker-compose.yaml:

services:  code-server:    image: linuxserver/code-server:4.96.1    container_name: code-server    restart: unless-stopped    #ports:    #  - 8443:8443    volumes:      - ./config:/config    environment:      - PUID=1000      - PGID=1000      - TZ=Europe/Kyiv    labels:      - "traefik.enable=true"      - "traefik.http.routers.code-server.rule=Host(`vscode.example.com`)"      - "traefik.http.routers.code-server.entrypoints=https"      - "traefik.http.routers.code-server.tls=true"      - "traefik.http.services.code-server.loadbalancer.server.port=8443"      - "traefik.docker.network=traefik"    security_opt:      - no-new-privileges:true    networks:      traefik:    healthcheck:      # causes Code Server to fail      test: "curl -fksSL http://localhost:8443/healthz | grep -o alive || exit 1"      # works fine      # test: ['CMD', 'curl', '-fksSL', 'http://localhost:8443/healthz']      start_period: 60s      interval: 60s      timeout: 20s      retries: 3networks:  traefik:    external: true
You must be logged in to vote

Replies: 1 comment 1 reply

Comment options

expired just means nothing has connected to it recently, code-server is still up and running as long as you get any valid 200 response from that endpoint.

You must be logged in to vote
1 reply
@code-asher
Comment options

expired does seem confusing though. It probably should have been "inactive" instead.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Labels
None yet
2 participants
@lordlightman@code-asher

[8]ページ先頭

©2009-2025 Movatter.jp