CDIST-TYPE__DOCKER_STACK(7)

πŸ’– cdist-type__docker_stack πŸ’–

okay bestie, so this is cdist-type__docker_stack from the cdist manual pages (section 7, if you're keeping score) β€” and it's literally the type that manages your Docker stacks for you. no cap. 🐳✨


🌸 DESCRIPTION 🌸

This type manages service stacks. that's the whole vibe, she's a manager, she runs the stack, she's the main character of your swarm.

NOTE: ⚠️ so like… there is no easy way to tell whether a stack actually needs to be updated. meaning docker stack deploy gets run every single time this type is invoked. every time. it's giving "did you check?" energy. BUT β€” and this is important, bestie β€” that does not mean this type isn't idempotent. if Docker doesn't detect any changes, the existing stack just stays as it is. nothing happens. chill. 😌✨

✨ OPTIONAL PARAMETERS ✨

okay so these are optional, meaning you can pass them but you don't have to. the range, honestly.

  • compose-file β€” the path to your compose file πŸŽ€ and if it's - (that's a dash, bestie, just one little dash) then it reads from standard input instead. very demure. very mindful. 🌸
  • state β€” either 'present' or 'absent', and it defaults to 'present'. here's the breakdown, iykyk:
    • present β€” the stack is deployed πŸš€βœ¨
    • absent β€” the stack is removed πŸ’€πŸ‘‹

🌈 EXAMPLES 🌈

okay here's the moment you've all been waiting for, the actual usage, the serving:

# Deploys 'foo' stack defined in 'docker-compose.yml' compose file
__docker_stack foo --compose-file docker-compose.yml

look at her go. foo is the stack name, docker-compose.yml is the compose file, and she ate. πŸ’…


πŸ‘‘ AUTHORS πŸ‘‘

Δ½ubomΓ­r Kučera <lubomir.kucera.jr at gmail.com> β€” thank you for your service king 🫢


πŸŽ€ COPYING πŸŽ€

Copyright (C) 2018 Δ½ubomΓ­r Kučera. You can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. πŸ’œ


ungleich GmbH 2021 🌟


and that's the whole page bestie!! this was version 7.0.0 from Jul 31, 2022, brought to you by the cdist girlies, and honestly? iconic. go deploy some stacks. slay. πŸ¦‹πŸ’–βœ¨

πŸ“¦ where this page comes from