zoukankan      html  css  js  c++  java
  • Docker实践3: Docker常用命令(未完)

    查看容器及运行进程

    docker ps

    查看容器内部信息

    docker inspect container_id

    进入容器

    docker attach container_id

    退出容器

    docker kill container_id

    查看日志

    docker logs container_id

    删除容器

    docker rmi -f $container_name/TAG

    以shell脚本方式进入contain,后台启动weblogic

    docker run -t -i 1213-shell /bin/bash

    ./startWebLogic.sh &

    $

    修改docker容器并保存

    先修改docker USER为root

    然后build一个新image,通过shell脚本进入container

    运行 yum install firefox(或者其他修改命令)

    exit退出后,通过docker commit $container_id 1213-shell

    来commit,然后新的容器保留在1213-shell的最新版本中。

    通过proxy进行docker pull

    解决办法(以centos为例,其他系统类似):

    修改/etc/sysconfig/docker

    HTTP_PROXY=http://186.100.4.107:808
    http_proxy=$HTTP_PROXY
    HTTPS_PROXY=$HTTP_PROXY
    https_proxy=$HTTP_PROXY
    export HTTP_PROXY HTTPS_PROXY http_proxy https_proxy

  • 相关阅读:
    VBA键码常数
    枚举
    海龟交易法则及头寸
    HQL.TOP
    jquery.cookie
    机械操作产品分析.
    Repeater排序2
    Repeater排序
    json
    LoginStatus注销控件
  • 原文地址:https://www.cnblogs.com/ericnie/p/5192384.html
Copyright © 2011-2022 走看看