Tony Narlock
2015-04-21 11:50:34 UTC
Hi Fabric users,
I wanted to get an idea of how much of a desire there is for this.
I use both Fabric and a Configuration management system called Salt on my
projects. Salt is permissively licensed and and has a superb, pythonic
architecture. I love salt for it's relatively simple declarative configs,
but most importantly, it's automated detection of remote systems, module
library and state library.
The issue is - there is a huge void in many projects where they're not big
enough to warrant the upkeep of maintaining configuration manager recipes,
but fabfile's tasks are starting to duplicate functionality a config
manager would normally handle. Also if working on a team, there's the issue
of colleagues being willing to accept a learning curve.
Fabric is an easier pill to swallow. As a task runner, it's front-end
implementation is more nimble that a configuration manager for
small-to-medium complexity scenarios.
Fabric has two projects so far that imitate configuration manager require /
states / cookbooks:
- Cuisine: https://github.com/sebastien/cuisine
- Fabtools https://github.com/ronnix/fabtools
Fabtools has worked like a charm for me - with the exception that requires
are nowhere near as resilient as salt states.
As an example, task a look at ``salt.states.git.latest`` handling of edge
cases, compared to ``fabtools.requires.git.working_copy``:
- Salt:
https://github.com/saltstack/salt/blob/000de9597475afa59b0cd6c7c1f6c3dc1c66a0bc/salt/states/git.py#L39
Fabtools:
https://github.com/ronnix/fabtools/blob/85f5828c84351a91c29bd2be1544d1922a36f436/fabtools/require/git.py#L51
Saltstack's states are also backed by tests:
https://github.com/saltstack/salt/blob/000de9597475afa59b0cd6c7c1f6c3dc1c66a0bc/tests/unit/states/git_test.py
.
This is just one example of how salt maintains a superb depth / breadth of
remote system execution commands / recipes. Another way to put it into
perspective:
http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.git.html
is to http://fabtools.readthedocs.org/en/latest/api/git.html
like http://docs.saltstack.com/en/latest/ref/states/all/salt.states.git.html
is to http://fabtools.readthedocs.org/en/latest/api/require/git.html
I have a *very rough* proof of concept demo:
https://gist.github.com/tony/6d8d975c817d2e4d43dd
Without delving into the complexities of things technically - I want to get
an idea from your POV and experiences with your fabric projects:
- does you here have any sort of gap to fill with fabric where you would
benefit from stuff like:
# make sure vim pkg is installed and latest, if not, install/update
debpkg.latest('vim')
# make sure nginx an nginx site has config file as a template
# in /etc/nginx/sites.avail, linked, and service is, running
nginx.running(**settings)
- would anything inside of / salt.modules.* [1] salt.states.* [2] be
helpful to you if you could access it pythonically via fabric?
- Do you already use a tool like cuisine / fabric and wish you had access
to more commands/requires/cookbooks?
Thank you!
Tony Narlock
[1]
http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.git.html
[2] http://docs.saltstack.com/en/latest/ref/states/all/salt.states.git.html
I wanted to get an idea of how much of a desire there is for this.
I use both Fabric and a Configuration management system called Salt on my
projects. Salt is permissively licensed and and has a superb, pythonic
architecture. I love salt for it's relatively simple declarative configs,
but most importantly, it's automated detection of remote systems, module
library and state library.
The issue is - there is a huge void in many projects where they're not big
enough to warrant the upkeep of maintaining configuration manager recipes,
but fabfile's tasks are starting to duplicate functionality a config
manager would normally handle. Also if working on a team, there's the issue
of colleagues being willing to accept a learning curve.
Fabric is an easier pill to swallow. As a task runner, it's front-end
implementation is more nimble that a configuration manager for
small-to-medium complexity scenarios.
Fabric has two projects so far that imitate configuration manager require /
states / cookbooks:
- Cuisine: https://github.com/sebastien/cuisine
- Fabtools https://github.com/ronnix/fabtools
Fabtools has worked like a charm for me - with the exception that requires
are nowhere near as resilient as salt states.
As an example, task a look at ``salt.states.git.latest`` handling of edge
cases, compared to ``fabtools.requires.git.working_copy``:
- Salt:
https://github.com/saltstack/salt/blob/000de9597475afa59b0cd6c7c1f6c3dc1c66a0bc/salt/states/git.py#L39
Fabtools:
https://github.com/ronnix/fabtools/blob/85f5828c84351a91c29bd2be1544d1922a36f436/fabtools/require/git.py#L51
Saltstack's states are also backed by tests:
https://github.com/saltstack/salt/blob/000de9597475afa59b0cd6c7c1f6c3dc1c66a0bc/tests/unit/states/git_test.py
.
This is just one example of how salt maintains a superb depth / breadth of
remote system execution commands / recipes. Another way to put it into
perspective:
http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.git.html
is to http://fabtools.readthedocs.org/en/latest/api/git.html
like http://docs.saltstack.com/en/latest/ref/states/all/salt.states.git.html
is to http://fabtools.readthedocs.org/en/latest/api/require/git.html
I have a *very rough* proof of concept demo:
https://gist.github.com/tony/6d8d975c817d2e4d43dd
Without delving into the complexities of things technically - I want to get
an idea from your POV and experiences with your fabric projects:
- does you here have any sort of gap to fill with fabric where you would
benefit from stuff like:
# make sure vim pkg is installed and latest, if not, install/update
debpkg.latest('vim')
# make sure nginx an nginx site has config file as a template
# in /etc/nginx/sites.avail, linked, and service is, running
nginx.running(**settings)
- would anything inside of / salt.modules.* [1] salt.states.* [2] be
helpful to you if you could access it pythonically via fabric?
- Do you already use a tool like cuisine / fabric and wish you had access
to more commands/requires/cookbooks?
Thank you!
Tony Narlock
[1]
http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.git.html
[2] http://docs.saltstack.com/en/latest/ref/states/all/salt.states.git.html