我有基于xubuntu的linux。
我已经安装了码头工人。
但是对于我的基础架构,我需要使用docker-machine
作为管理者。
问题是docker-machine
在默认情况下无法查看~/.docker
,因此看不到我的图像。我确实尝试将MACHINE_STORAGE_PATH
变量设置为overlay2
存储驱动程序使用的变量(来自此answers),但是它们都不起作用。即使我的码头工人有1台正在运行的计算机,码头工人计算机也看不到。
>docker-machine active
No active host found
并且:
>docker info
Containers: 17
Running: 1
Paused: 0
Stopped: 16
Images: 15
Server Version: 18.09.0
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: c4446665cb9c30056f4998ed953e6d4ff22c7c39
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: fec3683
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.16.13-galliumos
Operating System: GalliumOS 3.0
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 3.791GiB
Name: galliumos
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine
如何配置docker-machine
以查看我的docker映像?
这是我的/var/lib/docker
的简化结构:
/var/lib/docker
├── builder
│ └── fscache.db
├── buildkit
│ ├── cache.db
│ ├── content
│ │ └── ingest
│ ├── executor
│ ├── metadata.db
│ └── snapshots.db
├── containers
│ ├── 077f50df3a86911d1d715f6658e9a0984b16041ebdf7a9497c90a7185c63c17a
│ │ ├── 077f50df3a86911d1d715f6658e9a0984b16041ebdf7a9497c90a7185c63c17a-json.log
│ │ ├── checkpoints
│ │ ├── config.v2.json
│ │ ├── hostconfig.json
│ │ ├── hostname
│ │ ├── hosts
│ │ ├── mounts
│ │ │ └── shm
│ │ ├── resolv.conf
│ │ └── resolv.conf.hash
├── image
│ └── overlay2
│ ├── distribution
│ │ ├── diffid-by-digest
│ │ │ └── sha256
│ │ │ └── fa83472a3562898caaf8d77542181a473a84039376f2ba56254619d9317ba00d
│ │ └── v2metadata-by-diffid
│ │ └── sha256
│ │ └── f75e64f96dbc610a00722afa3826745952db8d1416f6405e7e87c20868b9f542
│ ├── imagedb
│ │ ├── content
│ │ │ └── sha256
│ │ │ └── d40668baebcb80ab9c13667d2c62ca359b52bba417415f257313b98fed17d1ef
│ │ └── metadata
│ │ └── sha256
│ │ └── d40668baebcb80ab9c13667d2c62ca359b52bba417415f257313b98fed17d1ef
│ │ └── parent
│ ├── layerdb
│ │ ├── mounts
│ │ │ └── fec9fa167f8f6944ca24c1c9fdffe8142392922ad9f8967f095ffdee536e4025
│ │ │ ├── init-id
│ │ │ ├── mount-id
│ │ │ └── parent
│ │ ├── sha256
│ │ │ └── eb91e8adb4541f0df58f6d896fee1355e04c0984b3104da1038178b8d6649b6b
│ │ │ ├── cache-id
│ │ │ ├── diff
│ │ │ ├── parent
│ │ │ ├── size
│ │ │ └── tar-split.json.gz
│ │ └── tmp
│ └── repositories.json
├── network
│ └── files
│ └── local-kv.db
├── overlay2
│ ├── 81957d0e7cac6b00a103bad4da4f12e8103f56f358902aa4c39d9d9b8164917a
│ │ ├── diff
│ │ │ └── go
│ │ │ └── bin
│ │ │ └── all-in-one-linux
│ │ └── link
│ ├── ffbbee81aeec171e1a70b27f3c3fc7ace6c0ca33dbfdd6d390b406d34b1c8b6d-init
│ │ ├── diff
│ │ │ ├── dev
│ │ │ │ ├── console
│ │ │ │ ├── pts
│ │ │ │ └── shm
│ │ │ ├── etc
│ │ │ │ ├── hostname
│ │ │ │ ├── hosts
│ │ │ │ ├── mtab -> /proc/mounts
│ │ │ │ └── resolv.conf
│ │ │ ├── proc
│ │ │ └── sys
│ │ ├── link
│ │ ├── lower
│ │ └── work
│ │ └── work
│ └── l
│ ├── 2N57ZPCEPUQ3TVUAH5HY2M526N -> ../ffbbee81aeec171e1a70b27f3c3fc7ace6c0ca33dbfdd6d390b406d34b1c8b6d/diff
│ └── ZOEHN3DWY3C3JS3UHQ634XJRAB -> ../114a646d7a311920e7ee0d958e6d480036303b7e9b220d056ac3823fb8d431bf/diff
├── plugins
│ ├── storage
│ │ └── blobs
│ │ └── tmp
│ └── tmp
├── runtimes
├── swarm
├── tmp
├── trust
└── volumes
├── 2ace0452ee4d6b6094ec704c3873843f6bb4e29c5d712241b15060da7d36e945
│ └── _data
└── metadata.db