matrix-docker-ansible-deploy icon indicating copy to clipboard operation
matrix-docker-ansible-deploy copied to clipboard

Clear separation between "setup-all" and "install-all" (or, separate role for downloads)

Open mooomooo opened this issue 1 year ago • 5 comments

I'd expect that when running setup-all instead of install-all, nothing would try to be installed; in my mind "install" also includes downloading images. However (at least) the following images try to get pulled:

  • exim-relay
  • postgres
  • synapse

I would imagine that the "Ensure X is pulled" tasks should not be tagged with setup-all.

... unless I'm misunderstanding the distinction between those two roles, in which case is there a "only create config files" role?

(For reference, I'm trying to revisit the solution proposed in https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/64#issuecomment-1043708435. The addsafetodo.py hack no longer works with many things moving to external dependencies.)

mooomooo avatar Dec 05 '24 23:12 mooomooo

install-all runs installation tasks for all services. Installation tasks include everything (directory creation, config files setup, systemd service placement, pulling of container images (unless they are pulled already), creating container networks, etc.

setup-all runs installation tasks for all services (like install-all), but also runs uninstallation tasks for services that are no longer in use.


What you're looking for (an "only create config files" Ansible tag you can run) does not exist.

spantaleev avatar Dec 06 '24 03:12 spantaleev

So rename setup-all to something else to prevent confusion?

luixxiul avatar Dec 06 '24 03:12 luixxiul

I'm not sure how this confusion arises.

How does one get the expectation that "setup" will only create some config files, but will not do other parts of the setup (in this case: ensuring container images are pulled or built, in case of self-building)?

spantaleev avatar Dec 06 '24 03:12 spantaleev

Thanks for your clarification.

I'm not sure how this confusion arises.

(I'll note that although "only create config files" is in fact what I want, this issue was more meant to focus on the distinction between "modifying the system" vs not.)

My confusion (just speaking solely for myself here) arose because "setup" to me sounds like it should be independent of "installation"--a task is either a setup task or an install task, but not both. (Although I would buy "install" referring to a superset that includes "setup", simply for convenience.) And so, if there is to be a distinction between "setup" and "install", given the terminology, "install" is the one that allows modifying the system (which includes pulling images), while "setup" would not.

Going back to the Dark Times, I was mapping "install" to the old make install, with "setup" therefore being ./configure, and maybe make as well. Everything other than an explicit command including the word "install" should be expected to not contaminate anything outside of the local directory.

Regardless though, I don't find the equivalence "setup" == "install plus more stuff" intuitive at all. But again, that's probably just my personal language expectations.

mooomooo avatar Dec 06 '24 20:12 mooomooo

(Trying to avoid hijacking this issue)

I don't find the equivalence "setup" == "install plus more stuff" intuitive at all. But again, that's probably just my personal language expectations.

For more than four years I've autofilled the command on the terminal emulator (which definitely is not a good habit…), and did not realize the real difference between install-* and setup-* until last month; I've used the command setup-all as the documentation instructs, without really thinking about what is to be "set up" with it.

That being said, my terminology is so limited that a combination better than the current one (install-* and setup-*) do not come up.

  • "config-all" and "setup-all" : no, because the task to "config-*" does not exist
  • "install-all" and "replicate-all": "replicate" is not intuitive
  • "install-all" and "manage-all": ?
  • "install-all" and "maintain-all": ?
  • "install-all" and "install-and-uninstall-all": too long
  • "install-all" and "iu-all" (install-and-uninstall): not understandable, though iu is quite short
  • "install-all" and "sync-all": might be better than above, but "sync" rather sounds data synchronization, which running it does not do :thinking:

luixxiul avatar Dec 10 '24 11:12 luixxiul