From 754bbf7a25a8dda49b5d08ef0d0443bbf5af0e36 Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Sun, 7 Apr 2024 13:41:34 -0500 Subject: new repository --- ...rence%2Fcommandline%2Fstack_deploy%2Findex.html | 60 ++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 devdocs/docker/engine%2Freference%2Fcommandline%2Fstack_deploy%2Findex.html (limited to 'devdocs/docker/engine%2Freference%2Fcommandline%2Fstack_deploy%2Findex.html') diff --git a/devdocs/docker/engine%2Freference%2Fcommandline%2Fstack_deploy%2Findex.html b/devdocs/docker/engine%2Freference%2Fcommandline%2Fstack_deploy%2Findex.html new file mode 100644 index 00000000..d82ce2ca --- /dev/null +++ b/devdocs/docker/engine%2Freference%2Fcommandline%2Fstack_deploy%2Findex.html @@ -0,0 +1,60 @@ +

docker stack deploy


Deploy a new stack or update an existing stack

Usage

$ docker stack deploy [OPTIONS] STACK
+

Refer to the options section for an overview of available OPTIONS for this command.

Description

Create and update a stack from a compose file on the swarm.

Note

This is a cluster management command, and must be executed on a swarm manager node. To learn about managers and workers, refer to the Swarm mode section in the documentation.

For example uses of this command, refer to the examples section below.

Options

Name, shorthand Default Description
+--compose-file , -c + Path to a Compose file, or "-" to read from stdin
--namespace +deprecatedKubernetes
Kubernetes namespace to use
--prune +Swarm
Prune services that are no longer referenced
--resolve-image always +Swarm
Query the registry to resolve image digest and supported platforms ("always"|"changed"|"never")
--with-registry-auth +Swarm
Send registry authentication details to Swarm agents
--kubeconfig +deprecatedKubernetes
Kubernetes config file
--orchestrator +deprecated
Orchestrator to use (swarm|kubernetes|all)

Examples

Compose file

The deploy command supports compose file version 3.0 and above.

$ docker stack deploy --compose-file docker-compose.yml vossibility
+
+Ignoring unsupported options: links
+
+Creating network vossibility_vossibility
+Creating network vossibility_default
+Creating service vossibility_nsqd
+Creating service vossibility_logstash
+Creating service vossibility_elasticsearch
+Creating service vossibility_kibana
+Creating service vossibility_ghollector
+Creating service vossibility_lookupd
+

The Compose file can also be provided as standard input with --compose-file -:

$ cat docker-compose.yml | docker stack deploy --compose-file - vossibility
+
+Ignoring unsupported options: links
+
+Creating network vossibility_vossibility
+Creating network vossibility_default
+Creating service vossibility_nsqd
+Creating service vossibility_logstash
+Creating service vossibility_elasticsearch
+Creating service vossibility_kibana
+Creating service vossibility_ghollector
+Creating service vossibility_lookupd
+

If your configuration is split between multiple Compose files, e.g. a base configuration and environment-specific overrides, you can provide multiple --compose-file flags.

$ docker stack deploy --compose-file docker-compose.yml -c docker-compose.prod.yml vossibility
+
+Ignoring unsupported options: links
+
+Creating network vossibility_vossibility
+Creating network vossibility_default
+Creating service vossibility_nsqd
+Creating service vossibility_logstash
+Creating service vossibility_elasticsearch
+Creating service vossibility_kibana
+Creating service vossibility_ghollector
+Creating service vossibility_lookupd
+

You can verify that the services were correctly created:

$ docker service ls
+
+ID            NAME                               MODE        REPLICAS  IMAGE
+29bv0vnlm903  vossibility_lookupd                replicated  1/1       nsqio/nsq@sha256:eeba05599f31eba418e96e71e0984c3dc96963ceb66924dd37a47bf7ce18a662
+4awt47624qwh  vossibility_nsqd                   replicated  1/1       nsqio/nsq@sha256:eeba05599f31eba418e96e71e0984c3dc96963ceb66924dd37a47bf7ce18a662
+4tjx9biia6fs  vossibility_elasticsearch          replicated  1/1       elasticsearch@sha256:12ac7c6af55d001f71800b83ba91a04f716e58d82e748fa6e5a7359eed2301aa
+7563uuzr9eys  vossibility_kibana                 replicated  1/1       kibana@sha256:6995a2d25709a62694a937b8a529ff36da92ebee74bafd7bf00e6caf6db2eb03
+9gc5m4met4he  vossibility_logstash               replicated  1/1       logstash@sha256:2dc8bddd1bb4a5a34e8ebaf73749f6413c101b2edef6617f2f7713926d2141fe
+axqh55ipl40h  vossibility_vossibility-collector  replicated  1/1       icecrime/vossibility-collector@sha256:f03f2977203ba6253988c18d04061c5ec7aab46bca9dfd89a9a1fa4500989fba
+

Parent command

Command Description
docker stack Manage Docker stacks
Command Description
docker stack deploy Deploy a new stack or update an existing stack
docker stack ls List stacks
docker stack ps List the tasks in the stack
docker stack rm Remove one or more stacks
docker stack services List the services in the stack
+

+ © 2019 Docker, Inc.
Licensed under the Apache License, Version 2.0.
Docker and the Docker logo are trademarks or registered trademarks of Docker, Inc. in the United States and/or other countries.
Docker, Inc. and other parties may also have trademark rights in other terms used herein.
+ https://docs.docker.com/engine/reference/commandline/stack_deploy/ +

+
-- cgit v1.2.3