specify max log json file size in docker compose

Your yaml syntax isn’t quite correct. The documentation says it should be options not log-opt (https://docs.docker.com/compose/compose-file/#logging). Try this?

services:
    service_name:        
        logging:
            driver: "json-file"
            options:
                max-size: "50m"

You should define logging section in each one of your services not directly in root of docker-compose.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)