4-Docker命令之docker events

发布时间:2023-12-24 06:28:20

1.docker events介绍

docker events命令是用来打印出实时的系统事件

2.docker events用法

docker events [参数]

[root@centos79 ~]# docker events --help

Usage:  docker events [OPTIONS]

Get real time events from the server

Aliases:
  docker system events, docker events

Options:
  -f, --filter filter   Filter output based on conditions provided
      --format string   Format output using a custom template:
                        'json':             Print in JSON format
                        'TEMPLATE':         Print output using the given Go template.
                        Refer to https://docs.docker.com/go/formatting/ for more information about formatting output with templates
      --since string    Show all events created since timestamp
      --until string    Stream events until this timestamp
[root@centos79 ~]# 

3.实例

3.1.显示某个时间段的事件

命令:

docker events -f "image"="c

文章来源:https://blog.csdn.net/z19861216/article/details/134822300
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。