github.com/jiasir/docker@v1.3.3-0.20170609024000-252e610103e7/docs/reference/commandline/stack_rm.md (about)

     1  ---
     2  title: "stack rm"
     3  description: "The stack rm command description and usage"
     4  keywords: "stack, rm, remove, down"
     5  ---
     6  
     7  <!-- This file is maintained within the docker/docker Github
     8       repository at https://github.com/docker/docker/. Make all
     9       pull requests against that repo. If you see this file in
    10       another repository, consider it read-only there, as it will
    11       periodically be overwritten by the definitive file. Pull
    12       requests which include edits to this file in other repositories
    13       will be rejected.
    14  -->
    15  
    16  # stack rm
    17  
    18  ```markdown
    19  Usage:  docker stack rm STACK [STACK...]
    20  
    21  Remove one or more stacks
    22  
    23  Aliases:
    24    rm, remove, down
    25  
    26  Options:
    27        --help   Print usage
    28  ```
    29  
    30  ## Description
    31  
    32  Remove the stack from the swarm. This command has to be run targeting
    33  a manager node.
    34  
    35  ## Examples
    36  
    37  ### Remove a stack
    38  
    39  This will remove the stack with the name `myapp`. Services, networks, and secrets associated with the stack will be removed.
    40  
    41  ```bash
    42  $ docker stack rm myapp
    43  
    44  Removing service myapp_redis
    45  Removing service myapp_web
    46  Removing service myapp_lb
    47  Removing network myapp_default
    48  Removing network myapp_frontend
    49  ```
    50  
    51  ### Remove multiple stacks
    52  
    53  This will remove all the specified stacks, `myapp` and `vossibility`. Services, networks, and secrets associated with all the specified stacks will be removed.
    54  
    55  ```bash
    56  $ docker stack rm myapp vossibility
    57  
    58  Removing service myapp_redis
    59  Removing service myapp_web
    60  Removing service myapp_lb
    61  Removing network myapp_default
    62  Removing network myapp_frontend
    63  Removing service vossibility_nsqd
    64  Removing service vossibility_logstash
    65  Removing service vossibility_elasticsearch
    66  Removing service vossibility_kibana
    67  Removing service vossibility_ghollector
    68  Removing service vossibility_lookupd
    69  Removing network vossibility_default
    70  Removing network vossibility_vossibility
    71  ```
    72  
    73  ## Related commands
    74  
    75  * [stack deploy](stack_deploy.md)
    76  * [stack ls](stack_ls.md)
    77  * [stack ps](stack_ps.md)
    78  * [stack services](stack_services.md)