Skip to content

added curl command to aid with healthchecks#22

Open
skalavala wants to merge 1 commit intogihad:masterfrom
skalavala:patch-1
Open

added curl command to aid with healthchecks#22
skalavala wants to merge 1 commit intogihad:masterfrom
skalavala:patch-1

Conversation

@skalavala
Copy link
Copy Markdown

when running this using docker-compose, we could automatically do health check if there is a curl command available inside the container.

  streamer:
    container_name: camera_streamer
    image: gihad/streamer
    restart: always
    environment:
      - PARAMETERS=xxx
    volumes:
      - /tmp/stream:/tmp/stream
    ports:
      - 8080:80
    healthcheck:
      test:
        [
          "CMD",
          "curl",
          "-f",
          "http://192.168.xxx.xxx:8080/mycamerafeed.m3u8"
        ]
      interval: 1m
      timeout: 10s
      retries: 3

when running this using docker-compose, we could automatically do health check if there is a curl command available inside the container. 
```
  streamer:
    container_name: camera_streamer
    image: gihad/streamer
    restart: always
    environment:
      - PARAMETERS=xxx
    volumes:
      - /tmp/stream:/tmp/stream
    ports:
      - 8080:80
    healthcheck:
      test:
        [
          "CMD",
          "curl",
          "-f",
          "http://192.168.xxx.xxx:8080/mycamerafeed.m3u8"
        ]
      interval: 1m
      timeout: 10s
      retries: 3
```
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

Successfully merging this pull request may close these issues.

1 participant