标签:time rar secure lob try att htm run min
配置加速器(最新版的配置方法) [root@ming2 containers]# vim registries.conf [root@ming2 containers]# cat registries.conf unqualified-search-registries = ["docker.io"] [[registry]] prefix = "" location = "https://8v1ihtvi.mirror.aliyuncs.com" 老版本则为 [registries.search] registries = [‘docker.io‘] location = "mirrors.tuna.tsinghua.edu.cn/" [registries.insecure] registries = [] [registries.block] registries = []
拉取镜像
[root@ming2 containers]# podman pull nginx
Trying to pull docker.io/nginx:latest...Getting image source
Copying blob 45b42c59be33: 25.84 MiB / 25.84 MiB [==========
Copying blob 8acc495f1d91: 25.34 MiB / 25.34 MiB [==========
Copying blob ec3bd7de90d7: 599 B / 599 B [==================
Copying blob 19e2441aeeab: 894 B / 894 B [==================
Copying blob f5a38c5f8d4e: 666 B / 666 B [==================
Copying blob 83500d851118: 1.38 KiB / 1.38 KiB [============
Copying config 35c43ace9216: 7.55 KiB / 7.55 KiB [==========
Writing manifest to image destination
Storing signatures
35c43ace9216212c0f0e546a65eec93fa9fc8e96b25880ee222b7ed2ca1
登入普通用户 创建用户跟组 uid=994(wangming) gid=991(wangming) 组=991(wangming) [root@ming2 ~]# userdel wangming [root@ming2 ~]# useradd wm [root@ming2 ~]# su - wm [wm@ming2 ~]$ ls [wm@ming2 ~]$ pwd /home/wm
查询已启动容器 [wm@ming2 ~]$ podman ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 拉取容器 [wm@ming2 ~]$ podman pull nginx [wm@ming2 ~]$ podman images REPOSITORY TAG IMAGE ID CREATED SIZE docker.io/library/nginx latest 35c43ace9216 2 weeks ago 137 MB、 拉取并启动busybox [wm@ming2 ~]$ podman run -it --rm busybox /bin/sh Trying to pull docker.io/busybox:latest...Getting image source signatures Copying blob 8b3d7e226fab: 746.79 KiB / 746.79 KiB [===] 3s Copying config a9d583973f65: 1.42 KiB / 1.42 KiB [=====] 0s Writing manifest to image destination Storing signatures / # [wm@ming2 ~]$ podman ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 22e5631fe0e7 docker.io/library/busybox:latest /bin/sh 2 minutes ago Up 2 minutes ago loving_wilson 不等入查看容器操作的内容 [wm@ming2 ~]$ podman attach 510b69c7bd27 (接容器id) 查看最新启动的容器信息 [wm@ming2 ~]$ podman inspect -l 查看容器的top信息 [wm@ming2 ~]$ podman top sharp_swartz USER PID PPID %CPU ELAPSED TTY TIME COMMAND root 1 0 0.000 21.286676886s pts/0 0s nginx: master process nginx -g daemon off; nginx 30 1 0.000 21.287218883s pts/0 0s nginx: worker process 删除一个最新的容器 [wm@ming2 ~]$ podman run -d nginx 6df2d545b2ed7a707cac544f424fa9f2bdc553f6b2cb82b13e4638ff1ff5dbf5 [wm@ming2 ~]$ podman ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 6df2d545b2ed docker.io/library/nginx:latest /docker-entrypoin... 4 seconds ago Up 4 seconds ago stoic_bassi [wm@ming2 ~]$ podman rm -f --latest 6df2d545b2ed7a707cac544f424fa9f2bdc553f6b2cb82b13e4638ff1ff5dbf5 [wm@ming2 ~]$ podman ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
每个容器的uuid的范围,每个一用户的有65536个值 [root@ming2 containers]# cat /etc/subuid wm:100000:65536
podman的详细使用方法,查看使用方法
标签:time rar secure lob try att htm run min
原文地址:https://www.cnblogs.com/wangming/p/14512820.html