importrequests# 步骤一:获取容器IDcontainer_id="your-container-id"# 步骤二:获取容器信息url=f"http://localhost/containers/{container_id}/json"response=requests.get(url)container_info=response.json()# 步骤三:提取运行命令run_command=container_info["Config"]["Cmd"]# 打印运行命令print("容器运行命令...
WARNING: image with reference cucker/get_command_4_run_container was found but does not match the specified platform: wanted linux/arm64/v8, actual: linux/amd64解决 这样的错误是因为在下载镜像时没有指定平台 1 docker pull <镜像名称> --platform linux/arm64 __EOF__ 本文作者...