亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

目錄 搜尋
Compose About versions and upgrading (Compose) ASP.NET Core + SQL Server on Linux (Compose) CLI environment variables (Compose) Command-line completion (Compose) Compose(組成) Compose command-line reference(組合命令行參考) Control startup order (Compose) Django and PostgreSQL (Compose) Docker stacks and distributed application bundles (Compose) docker-compose build(docker-compose構(gòu)建) docker-compose bundle docker-compose config docker-compose create docker-compose down docker-compose events docker-compose exec docker-compose help docker-compose images docker-compose kill docker-compose logs docker-compose pause docker-compose port docker-compose ps docker-compose pull docker-compose push docker-compose restart docker-compose rm docker-compose run docker-compose scale docker-compose start docker-compose stop docker-compose top docker-compose unpause docker-compose up Environment file (Compose) Environment variables in Compose Extend services in Compose Frequently asked questions (Compose) Getting started (Compose) Install Compose Link environment variables (deprecated) (Compose) Networking in Compose Overview of Docker Compose Overview of docker-compose CLI Quickstart: Compose and WordPress Rails and PostgreSQL (Compose) Sample apps with Compose Using Compose in production Using Compose with Swarm Engine .NET Core application (Engine) About images, containers, and storage drivers (Engine) Add nodes to the swarm (Engine) Apply custom metadata (Engine) Apply rolling updates (Engine) apt-cacher-ng Best practices for writing Dockerfiles (Engine) Binaries (Engine) Bind container ports to the host (Engine) Breaking changes (Engine) Build your own bridge (Engine) Configure container DNS (Engine) Configure container DNS in user-defined networks (Engine) CouchDB (Engine) Create a base image (Engine) Create a swarm (Engine) Customize the docker0 bridge (Engine) Debian (Engine) Default bridge network Delete the service (Engine) Deploy a service (Engine) Deploy services to a swarm (Engine) Deprecated Engine features Docker container networking (Engine) Docker overview (Engine) Docker run reference (Engine) Dockerfile reference (Engine) Dockerize an application Drain a node (Engine) Engine FAQ (Engine) Fedora (Engine) Get started (Engine) Get started with macvlan network driver (Engine) Get started with multi-host networking (Engine) How nodes work (Engine) How services work (Engine) Image management (Engine) Inspect the service (Engine) Install Docker (Engine) IPv6 with Docker (Engine) Join nodes to a swarm (Engine) Legacy container links (Engine) Lock your swarm (Engine) Manage nodes in a swarm (Engine) Manage sensitive data with Docker secrets (Engine) Manage swarm security with PKI (Engine) Manage swarm service networks (Engine) Migrate to Engine 1.10 Optional Linux post-installation steps (Engine) Overview (Engine) PostgreSQL (Engine) Raft consensus in swarm mode (Engine) Riak (Engine) Run Docker Engine in swarm mode Scale the service (Engine) SDKs (Engine) Select a storage driver (Engine) Set up for the tutorial (Engine) SSHd (Engine) Storage driver overview (Engine) Store service configuration data (Engine) Swarm administration guide (Engine) Swarm mode key concepts (Engine) Swarm mode overlay network security model (Engine) Swarm mode overview (Engine) Understand container communication (Engine) Use multi-stage builds (Engine) Use swarm mode routing mesh (Engine) Use the AUFS storage driver (Engine) Use the Btrfs storage driver (Engine) Use the Device mapper storage driver (Engine) Use the OverlayFS storage driver (Engine) Use the VFS storage driver (Engine) Use the ZFS storage driver (Engine) Engine: Admin Guide Amazon CloudWatch logs logging driver (Engine) Bind mounts (Engine) Collect Docker metrics with Prometheus (Engine) Configuring and running Docker (Engine) Configuring logging drivers (Engine) Control and configure Docker with systemd (Engine) ETW logging driver (Engine) Fluentd logging driver (Engine) Format command and log output (Engine) Google Cloud logging driver (Engine) Graylog Extended Format (GELF) logging driver (Engine) Journald logging driver (Engine) JSON File logging driver (Engine) Keep containers alive during daemon downtime (Engine) Limit a container's resources (Engine) Link via an ambassador container (Engine) Log tags for logging driver (Engine) Logentries logging driver (Engine) PowerShell DSC usage (Engine) Prune unused Docker objects (Engine) Run multiple services in a container (Engine) Runtime metrics (Engine) Splunk logging driver (Engine) Start containers automatically (Engine) Storage overview (Engine) Syslog logging driver (Engine) tmpfs mounts Troubleshoot volume problems (Engine) Use a logging driver plugin (Engine) Using Ansible (Engine) Using Chef (Engine) Using Puppet (Engine) View a container's logs (Engine) Volumes (Engine) Engine: CLI Daemon CLI reference (dockerd) (Engine) docker docker attach docker build docker checkpoint docker checkpoint create docker checkpoint ls docker checkpoint rm docker commit docker config docker config create docker config inspect docker config ls docker config rm docker container docker container attach docker container commit docker container cp docker container create docker container diff docker container exec docker container export docker container inspect docker container kill docker container logs docker container ls docker container pause docker container port docker container prune docker container rename docker container restart docker container rm docker container run docker container start docker container stats docker container stop docker container top docker container unpause docker container update docker container wait docker cp docker create docker deploy docker diff docker events docker exec docker export docker history docker image docker image build docker image history docker image import docker image inspect docker image load docker image ls docker image prune docker image pull docker image push docker image rm docker image save docker image tag docker images docker import docker info docker inspect docker kill docker load docker login docker logout docker logs docker network docker network connect docker network create docker network disconnect docker network inspect docker network ls docker network prune docker network rm docker node docker node demote docker node inspect docker node ls docker node promote docker node ps docker node rm docker node update docker pause docker plugin docker plugin create docker plugin disable docker plugin enable docker plugin inspect docker plugin install docker plugin ls docker plugin push docker plugin rm docker plugin set docker plugin upgrade docker port docker ps docker pull docker push docker rename docker restart docker rm docker rmi docker run docker save docker search docker secret docker secret create docker secret inspect docker secret ls docker secret rm docker service docker service create docker service inspect docker service logs docker service ls docker service ps docker service rm docker service scale docker service update docker stack docker stack deploy docker stack ls docker stack ps docker stack rm docker stack services docker start docker stats docker stop docker swarm docker swarm ca docker swarm init docker swarm join docker swarm join-token docker swarm leave docker swarm unlock docker swarm unlock-key docker swarm update docker system docker system df docker system events docker system info docker system prune docker tag docker top docker unpause docker update docker version docker volume docker volume create docker volume inspect docker volume ls docker volume prune docker volume rm docker wait Use the Docker command line (Engine) Engine: Extend Access authorization plugin (Engine) Docker log driver plugins Docker network driver plugins (Engine) Extending Engine with plugins Managed plugin system (Engine) Plugin configuration (Engine) Plugins API (Engine) Volume plugins (Engine) Engine: Security AppArmor security profiles for Docker (Engine) Automation with content trust (Engine) Content trust in Docker (Engine) Delegations for content trust (Engine) Deploying Notary (Engine) Docker security (Engine) Docker security non-events (Engine) Isolate containers with a user namespace (Engine) Manage keys for content trust (Engine) Play in a content trust sandbox (Engine) Protect the Docker daemon socket (Engine) Seccomp security profiles for Docker (Engine) Secure Engine Use trusted images Using certificates for repository client verification (Engine) Engine: Tutorials Engine tutorials Network containers (Engine) Get Started Part 1: Orientation Part 2: Containers Part 3: Services Part 4: Swarms Part 5: Stacks Part 6: Deploy your app Machine Amazon Web Services (Machine) Digital Ocean (Machine) docker-machine active docker-machine config docker-machine create docker-machine env docker-machine help docker-machine inspect docker-machine ip docker-machine kill docker-machine ls docker-machine provision docker-machine regenerate-certs docker-machine restart docker-machine rm docker-machine scp docker-machine ssh docker-machine start docker-machine status docker-machine stop docker-machine upgrade docker-machine url Driver options and operating system defaults (Machine) Drivers overview (Machine) Exoscale (Machine) Generic (Machine) Get started with a local VM (Machine) Google Compute Engine (Machine) IBM Softlayer (Machine) Install Machine Machine Machine CLI overview Machine command-line completion Machine concepts and help Machine overview Microsoft Azure (Machine) Microsoft Hyper-V (Machine) Migrate from Boot2Docker to Machine OpenStack (Machine) Oracle VirtualBox (Machine) Provision AWS EC2 instances (Machine) Provision Digital Ocean Droplets (Machine) Provision hosts in the cloud (Machine) Rackspace (Machine) VMware Fusion (Machine) VMware vCloud Air (Machine) VMware vSphere (Machine) Notary Client configuration (Notary) Common Server and signer configurations (Notary) Getting started with Notary Notary changelog Notary configuration files Running a Notary service Server configuration (Notary) Signer configuration (Notary) Understand the service architecture (Notary) Use the Notary client
文字

描述

更新服務(wù)

使用

docker service update [OPTIONS] SERVICE

備選方案

名字,簡寫

默認(rèn)

描述

--args


服務(wù)命令參數(shù)

--config-add


添加或更新服務(wù)上的配置文件

--config-RM


刪除配置文件

--constraint-add


添加或更新展示位置約束

--constraint-RM


刪除約束

--container-label-add


添加或更新容器標(biāo)簽

--container-label-rm


用鑰匙取出容器標(biāo)簽

--credential-spec


托管服務(wù)帳戶的憑證規(guī)范(僅限Windows)

--detach,-d

立即退出,而不是等待服務(wù)收斂

--dns-add


添加或更新自定義DNS服務(wù)器

--dns-option-add


添加或更新DNS選項(xiàng)

--dns-option-rm


刪除一個(gè)DNS選項(xiàng)

--dns-rm


刪除自定義的DNS服務(wù)器

--dns-search-add


添加或更新自定義DNS搜索域

--dns-search-rm


刪除一個(gè)DNS搜索域

--endpoint-mode


端點(diǎn)模式(vip或dnsrr)

--entrypoint


覆蓋圖像的默認(rèn)入口點(diǎn)

--env-add


添加或更新環(huán)境變量

--env-RM


刪除一個(gè)環(huán)境變量

--force

即使沒有更改需要,也強(qiáng)制更新

--group-add


向容器添加一個(gè)附加的補(bǔ)充用戶組

--group-RM


從容器中刪除先前添加的補(bǔ)充用戶組

--health-cmd


運(yùn)行以檢查運(yùn)行狀況的命令

--health-interval


運(yùn)行檢查之間的時(shí)間(ms | s | m | h)

--health-retries

0

需要報(bào)告不健康的連續(xù)失敗

--health-retries


在重新計(jì)數(shù)到不穩(wěn)定(ms | s | m | h)之前,容器初始化的開始時(shí)間段

--health-timeout


允許一次檢查運(yùn)行的最長時(shí)間(ms | s | m | h)

--host加


添加或更新自定義主機(jī)到IP映射(主機(jī):IP)

--host-RM


刪除自定義的主機(jī)到IP映射(主機(jī):IP)

--hostname


容器主機(jī)名

--image


服務(wù)圖片標(biāo)簽

--label-add


添加或更新服務(wù)標(biāo)簽

--label-RM


用鑰匙去除標(biāo)簽

--limit-CPU


限制CPU

--limit-memory

0

限制記憶

--log-driver


記錄驅(qū)動(dòng)程序的服務(wù)

--log-OPT


記錄驅(qū)動(dòng)程序選項(xiàng)

--mount-add


添加或更新服務(wù)上的裝載

--mount-RM


通過目標(biāo)路徑移除一個(gè)安裝

--network加


添加一個(gè)網(wǎng)絡(luò)

--network-RM


刪除網(wǎng)絡(luò)

--no-healthcheck

禁用任何容器指定的HEALTHCHECK

--no-resolve-image

不要查詢注冊(cè)表來解析圖像摘要和支持的平臺(tái)

--placement-PREF-ADD


添加展示位置首選項(xiàng)

--placement-PREF-RM


刪除展示位置偏好設(shè)置

--publish相加


添加或更新已發(fā)布的端口

--publish-RM


通過目標(biāo)端口刪除發(fā)布的端口

--quiet,-q

抑制進(jìn)度輸出

--read-only

將容器的根文件系統(tǒng)掛載為只讀

--replicas


任務(wù)數(shù)量

--reserve-CPU


預(yù)留CPU

--reserve-memory

0

保留內(nèi)存

--restart-condition


條件滿足時(shí)重新啟動(dòng)(“none”|“on-failure”|“any”)

--restart-delay


重啟嘗試之間的延遲(ns | us | ms | s | m | h)

--restart-max-attempts


放棄前的最大重啟次數(shù)

--restart-window


用于評(píng)估重新啟動(dòng)策略的窗口(ns | us | ms | s | m | h)

--rollback

回退到先前的規(guī)范

--rollback-delay

0

任務(wù)回滾之間的延遲(ns | us | ms | s | m | h)

--rollback-failure-action


回滾失敗的操作(“暫?!眧“繼續(xù)”)

--rollback-max-failure-ratio

0

在回滾期間容忍的失敗率

--rollback-monitor

0

每個(gè)任務(wù)回滾后監(jiān)視失敗的持續(xù)時(shí)間(ns | us | ms | s | m | h)

--rollback-order


回滾順序(“start-first”|“stop-first”)

--rollback-parallelism

0

同時(shí)回滾的任務(wù)的最大數(shù)量(0一次全部回滾)

--secret-add


添加或更新服務(wù)的秘密

--secret-RM


去掉一個(gè)秘密

--stop-grace-period


強(qiáng)制殺死一個(gè)容器之前的等待時(shí)間(ns | us | ms | s | m | h)

--stop-signal


停止容器的信號(hào)

--tty, -t

分配一個(gè)偽TTY

--update-delay

0

更新之間的延遲(ns | us | ms | s | m | h)

--update-failure-action


更新失敗的操作(“暫停”|“繼續(xù)”|“回滾”)

--update-max-failure-ratio

0

更新期間容錯(cuò)的失敗率

--update-monitor

0

(ns | us | ms | s | m | h)每個(gè)任務(wù)更新后的持續(xù)時(shí)間

--update-order


更新順序(“start-first”|“stop-first”)

--update-parallelism

0

同時(shí)更新的最大任務(wù)數(shù)(0個(gè)一次全部更新)

--user,-u


用戶名或UID(格式:<名稱| uid>:<組| gid>)

--with-registry-auth

向注冊(cè)代理發(fā)送注冊(cè)表認(rèn)證詳細(xì)信息

--workdir,-w


容器內(nèi)的工作目錄

父命令

命令

描述

docker 服務(wù)

管理服務(wù)

相關(guān)命令

命令

描述

docker  服務(wù)創(chuàng)建

創(chuàng)建一項(xiàng)新服務(wù)

docker  服務(wù)檢查

顯示一項(xiàng)或多項(xiàng)服務(wù)的詳細(xì)信息

docker  服務(wù)日志

獲取服務(wù)或任務(wù)的日志

docker  服務(wù)ls

列出服務(wù)

docker  服務(wù)ps

列出一項(xiàng)或多項(xiàng)服務(wù)的任務(wù)

docker  服務(wù)rm

刪除一項(xiàng)或多項(xiàng)服務(wù)

docker  服務(wù)規(guī)模

擴(kuò)展一個(gè)或多個(gè)復(fù)制服務(wù)

docker  服務(wù)更新

更新服務(wù)

擴(kuò)展描述

按照指定的參數(shù)描述更新服務(wù)。該命令必須以管理器節(jié)點(diǎn)為目標(biāo)運(yùn)行。參數(shù)與docker service create。相同。請(qǐng)參閱描述以獲取更多信息。

通常,更新服務(wù)只會(huì)導(dǎo)致服務(wù)的任務(wù)被替換為新服務(wù),如果對(duì)服務(wù)的更改需要重新創(chuàng)建任務(wù)才能生效。例如,只有更改--update-parallelism設(shè)置才會(huì)重新創(chuàng)建任務(wù),因?yàn)閱蝹€(gè)任務(wù)不受此設(shè)置的影響。但是,--force標(biāo)志將導(dǎo)致任務(wù)被重新創(chuàng)建。這可以用來執(zhí)行滾動(dòng)重啟,而不會(huì)對(duì)服務(wù)參數(shù)進(jìn)行任何更改。

實(shí)例

更新服務(wù)

$ docker service update --limit-cpu 2 redis

執(zhí)行滾動(dòng)重新啟動(dòng),不更改參數(shù)。

$ docker service update --force --update-parallelism 1 --update-delay 30s redis

在這個(gè)例子中,--force標(biāo)志導(dǎo)致服務(wù)的任務(wù)被關(guān)閉并被新的替換,即使其他參數(shù)通常都不會(huì)導(dǎo)致這種情況發(fā)生。--update-parallelism 1設(shè)置確保一次只替換一個(gè)任務(wù)(這是默認(rèn)行為)。--update-delay 30s設(shè)置在任務(wù)之間引入了30秒的延遲,以便滾動(dòng)重啟逐漸發(fā)生。

添加或移除掛載

使用--mount-add--mount-rm選項(xiàng)添加或刪除服務(wù)的綁定掛載或volume。

以下示例創(chuàng)建一個(gè)將test-datavolume掛載到的服務(wù)/somewhere。下一步更新服務(wù)以將other-volumevolume掛接到/somewhere-elsevolume,最后一步卸載/somewhere掛載點(diǎn),從而有效地移除test-datavolume。每個(gè)命令都會(huì)返回服務(wù)名稱。

  • --mount-add標(biāo)志采用了相同的參數(shù)--mount上的標(biāo)志service create。有關(guān)詳細(xì)信息,請(qǐng)參閱參考中的volume和綁定掛載部分service create。

  • --mount-rm標(biāo)志采用target安裝路徑。

$ docker service create \    --name=myservice \    --mount \
      type=volume,source=test-data,target=/somewhere \
    nginx:alpine \
    myservice

myservice

$ docker service update \    --mount-add \
      type=volume,source=other-volume,target=/somewhere-else \
    myservice

myservice

$ docker service update --mount-rm /somewhere myservice

myservice

恢復(fù)到服務(wù)的以前版本。

使用--rollback選項(xiàng)恢復(fù)到服務(wù)的前一個(gè)版本。

這將使服務(wù)恢復(fù)到最近一次配置之前的配置。docker service update命令。

下面的示例將服務(wù)的副本數(shù)量從4更新到5,然后回滾到以前的配置。

$ docker service update --replicas=5 web

web

$ docker service ls

ID            NAME  MODE        REPLICAS  IMAGE
80bvrzp6vxf3  web   replicated  0/5       nginx:alpine

回滾web服務(wù)...

$ docker service update --rollback web

web

$ docker service ls

ID            NAME  MODE        REPLICAS  IMAGE
80bvrzp6vxf3  web   replicated  0/4       nginx:alpine

其他選項(xiàng)也可以結(jié)合使用--rollback,例如,--update-delay 0s執(zhí)行任務(wù)之間沒有延遲的回滾:

$ docker service update \  --rollback \  --update-delay 0s
  web

web

服務(wù)也可以設(shè)置為在更新失敗時(shí)自動(dòng)回滾到以前的版本。要設(shè)置自動(dòng)回滾服務(wù),請(qǐng)使用--update-failure-action=rollback。如果成功更新失敗的部分任務(wù)超過了給定的值,將會(huì)觸發(fā)回滾--update-max-failure-ratio。

恢復(fù)操作的速率,并行性和其他參數(shù)由通過以下標(biāo)志傳遞的值確定:

  • --rollback-delay

  • --rollback-failure-action

  • --rollback-max-failure-ratio

  • --rollback-monitor

  • --rollback-parallelism

例如,設(shè)置的服務(wù)--update-parallelism 1 --rollback-parallelism 3將在正常更新期間一次更新一個(gè)任務(wù),但在回滾期間,一次會(huì)執(zhí)行3個(gè)任務(wù)。這些回滾參數(shù)在自動(dòng)回滾和使用手動(dòng)啟動(dòng)--rollback的回滾期間都被重視。

添加或刪除秘密

使用--secret-add--secret-rm選項(xiàng)添加或刪除服務(wù)的機(jī)密。

以下示例添加一個(gè)名為ssh-2并刪除的秘密ssh-1

$ docker service update \    --secret-add source=ssh-2,target=ssh-2 \    --secret-rm ssh-1 \
    myservice

使用模板更新服務(wù)

service update支持使用模板的一些標(biāo)志。請(qǐng)參閱service create參考。

上一篇: 下一篇: