Asked long ago, but I've also searched for that...
You can check the default logging driver with
ars@ars-thinkpad ~ $ docker system info | grep -i log
Logging Driver: json-file
Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
WARNING: No swap limit support
Alternatively,
ars@ars-thinkpad ~ $ docker info --format '{{.LoggingDriver}}'
json-file
To get the driver of the existing container,
ars@ars-thinkpad ~ $ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
a48314f1c163 tests_node3 "/pg/mmts/tests/dock…" 10 minutes ago Up 10 minutes 0.0.0.0:15434->5432/tcp node3
ars@ars-thinkpad ~ $ docker inspect a48314f1c163 | grep -i -C 5 log
},
"Image": "sha256:80493e979e72a027d07ef5db2c7486d1913ff4ae224eb8a5b93a93320f51844d",
"ResolvConfPath": "/var/lib/docker/containers/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df/resolv.conf",
"HostnamePath": "/var/lib/docker/containers/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df/hostname",
"HostsPath": "/var/lib/docker/containers/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df/hosts",
"LogPath": "/var/lib/docker/containers/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df-json.log",
"Name": "/node3",
"RestartCount": 0,
"Driver": "overlay2",
"Platform": "linux",
"MountLabel": "",
--
"AppArmorProfile": "unconfined",
"ExecIDs": null,
"HostConfig": {
"Binds": [],
"ContainerIDFile": "",
"LogConfig": {
"Type": "json-file",
"Config": {}
},
"NetworkMode": "tests_mtm_bridge",
"PortBindings": {
So it is json-file
with the actual log file path /var/lib/docker/containers/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df/a48314f1c16356f3cf534b273ea3871a26882d1466979c48e38611d8106594df-json.log
in my case.
See also
https://docs.docker.com/config/containers/logging/configure/