k8s使用配置文件创建容器

匿名 (未验证) 提交于 2019-12-03 00:15:02
例:apiVersion: v1 kind: Pod metadata: name: web spec: # specification of the pod’s contents restartPolicy: Never containers: - name: web image: "httpd"containerPort: 80使用kubectl create -f执行即可创建名为httpd的容器
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!