docker 启动容器

  • docker 生成本地image

    docker commit -a ephuizi -m “myapp 4.1.5 version” 993448234d20 myrep/myapp:4.1.5

  • 创建网桥,划分子网

    docker network create –subnet= mynetwork

  • 启动容器

    docker run –name hui3 –network=mynetwork –ip –cap-add SYS_ADMIN –device /dev/fuse –security-opt apparmor=unconfined -it –rm myrep/myapp:4.1.5 /bin/bash

  • 连接容器

    docker -exec -it 862f428a014c /bin/bash

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.