首页 > 代码库 > 003_如何正确的进入容器
003_如何正确的进入容器
一、
$ docker exec -it ele_zookeeper /bin/bash
二、
参考nsenter git地址=>https://github.com/jpetazzo/nsenter
arun:tmp arunyang$ docker run --rm jpetazzo/nsenter cat /nsenter > /tmp/nsenter && chmod +x /tmp/nsenter Unable to find image ‘jpetazzo/nsenter:latest‘ locally latest: Pulling from jpetazzo/nsenter 5c90d4a2d1a8: Pulling fs layer .......... 0c4337c5a938: Pulling fs layer 72024cea4c47: Waiting .......... 0c4337c5a938: Waiting c6c4c486dd77: Verifying Checksum c6c4c486dd77: Download complete .......... c6c4c486dd77: Pull complete 23f698ff1fd0: Download complete b39fba43fbdb: Verifying Checksum .......... 0ed6ac9f06ed: Pull complete .......... Digest: sha256:a30e7da907a9abb715027677c21468005beee06251b7737c86f84fa148d572b0 Status: Downloaded newer image for jpetazzo/nsenter:latest
arun:bin arunyang$ mv /tmp/nsenter /usr/local/bin/
003_如何正确的进入容器
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。