ERROR: for kiosk Container "a17f9a13941b" is unhealthy

Hello everyone, I’m trying to run a docker-compose.yml file in verdin mini, I just copied exactly the same example given by toradex and I’m trying to start it with docker compose up, but It is returning the error.

Could please help me ?

Hi @V_D_ALMEIDA ,

Can you attach the exact docker-compose.yml example that you’ve used?

Best regards,
Lucas Akira

version: “2.4”
services:
ihmestufateste1:
container_name: ihmestufateste1
platform: linux/arm64 torizon/debian:2-bullseye
networks:

  • backend
  • frontend
    ports:
  • “80:80”
    image: vdalmeida/ihmestufa

nodeestufateste1:
container_name: nodeestufateste1
platform: linux/arm64 torizon/debian:2-bullseye
networks:

  • backend
    ports:
  • “3000:3000”
    image: vdalmeida/nodeestufa

networks:
backend:
internal: true
frontend:
internal: false

Lucas, these are the dockerfile I’ve used to create the images

HTML application

FROM nginx

LABEL version=“1.0.0” description=“Teste Linux-Toradex” maintainer=“Victor Davi Almeida victor.davi@hotmail.com

RUN cd / && mkdir Arquivos && chmod 777 -R Arquivos/

COPY . /usr/share/nginx/html/

VOLUME /Arquivos/

EXPOSE 80

ENV API_URL=http://localhost:8000/api/
ENV API_BANCO=meu_site

WORKDIR /usr/share/nginx/html/

ENTRYPOINT [“/usr/sbin/nginx”]
CMD [“-g”, “daemon off;”]

Node.js Application

FROM node:16.15.1

RUN mkdir -p /usr/src/app

WORKDIR /usr/src/app

COPY package.json /usr/src/app/

RUN npm install

COPY . /usr/src/app

EXPOSE 3000

CMD [ “npm”, “start” ]

In the verdin I want to run these two containers, and I want to show the HTML+ javascript app in the LVDS display.

I dont know exactly how can I construct a docker-compose to successfull update via Torizon OTA.

What I was trying to was mixing these two containers with the weston and kiosk

version: “2.4”
services:

weston:
image: torizon/weston-vivante:2

Accept the EULA required to run imx8 vivante graphic drivers

environment:

  • ACCEPT_FSL_EULA=1

Required to get udev events from host udevd via netlink

network_mode: host
volumes:

  • type: bind
    source: /tmp
    target: /tmp
  • type: bind
    source: /dev
    target: /dev
  • type: bind
    source: /run/udev
    target: /run/udev
    cap_add:
  • CAP_SYS_TTY_CONFIG

Add device access rights through cgroup…

device_cgroup_rules:

… for tty0

  • ‘c 4:0 rmw’

… for tty7

  • ‘c 4:7 rmw’

… for /dev/input devices

  • ‘c 13:* rmw’
  • ‘c 199:* rmw’

… for /dev/dri devices

  • ‘c 226:* rmw’
    command: --developer weston-launch --tty=/dev/tty7 --user=torizon
    healthcheck:
    test: [“CMD”, “test”, “-S”, “/tmp/.X11-unix/X0”]
    interval: 5s
    timeout: 4s
    retries: 6
    start_period: 10s

#Stopped here
ihmestufateste1:
container_name: ihmestufateste1:latest
image: vdalmeida/ihmestufa
networks:

  • backend
  • frontend
    ports:
  • “80:80”

kiosk:
image: torizon/kiosk-mode-browser:2
security_opt:

… for /dev/dri devices

  • ‘c 226:* rmw’
    volumes:
  • type: bind
    source: /tmp
    target: /tmp
  • type: bind
    source: /var/run/dbus
    target: /var/run/dbus
  • type: bind
    source: /dev/dri
    target: /dev/dri
    depends_on:
  • ihmestufateste1
  • weston:
    condition: service_healthy

The error message indicates that the kiosk image can’t start because the healthcheck condition for it defined in the docker-compose.yml file fails.

It should go away as soon as all previous containers start successfully. That is, this should be gone if all your other docker-compose problems are solved.

Also, when outputting your file here please format your text with ctrl+e, that makes reading it much easier.

Best regards,
Lucas Akira