Mosquitto problem when not in local mode

I’ve successfully deployed a mosquitto container using this docker-compose file

    version: '2.1'
    networks: {}
      resin-data: {}
        build: mosquitto
          - 1884:1884
        restart: always

and this dockerfile

    FROM eclipse-mosquitto

    COPY ./mosquitto.conf /mosquitto/config/mosquitto.conf
    COPY ./pw_file /mosquitto/pw_file
    CMD ["/usr/sbin/mosquitto", "-c", "/mosquitto/config/mosquitto.conf"]

in local mode (using balena push DEVICE_IP), but when I disable local mode support I get this error
standard_init_linux.go:195: exec user process caused "exec format error" and the service is continuously restarting . Any ideas why this might happen?


Hi, could you provide the full log output of the build after balena push ... as there is other useful info in the output. If you could also run with the --logs flag then we will see much more.

@peris, adding to Rich’s message, it has occurred to me that “exec format error” is usually a case of trying to running binaries compiled for a different architecture, e.g. Intel x86 binaries on an ARM processor. Are you by any chance trying to run it on a Raspberry Pi? In which case, I would suggest changing the 'FROM eclipse-mosquitto' line to 'FROM arm32v6/eclipse-mosquitto' which I see exists on DockerHub:

Hey guys thanks for the quick responses. I should have mentioned that my target device is a Raspberry Pi. @pdcastro’s suggestion worked for me, but I don’t understand why it worked in local mode. In any case, my issue is resolved :slight_smile:

Thanks for the update!