清理 /var/lib/docker/containers 日志 注意 /var/lib/docker/ 为默认的 Docker RootDir #!/usr/bin/env bash search_dir=/var/lib/docker/containers for entry in "$search_dir"/* do #echo $entry/$(basename $entry)-json.log > $entry/$(basename $entry)-json.log done