So, got asked on twitter why ansible-commander isn't using sqlite.
Several reasons.
(A) At some point, ansible callbacks when using commander are going
to be writing a large amount of data in parallel to the database --
including possible activity remotely sent in via machines running
ansible-pull for those running at more massive scales. I do not
desire the database to block for insertions. This is somewhat minor,
everything adds up. These will include the latest facts per system,
the status of the last playbook per system, etc. Callbacks will be
expanded over time to inject a fair amount of useful data into ansible
commander.
(B) At some point in the future we (or a particular user) may decide
we need a "real" database, at this point, I do not want to bother
about cross database migration scripts. I'd rather/start/ with the
database now and save users the hassle of migration later.
(C) Maintaining schemas for multiple databases and testing them adds
development cost that I don't want to deal with at this point in time.
That may come later if there is sufficient demand, but right now,
it's a distraction.
(D) Seeing we have a seperate database all setup via
ansible-playbook, I don't really see it imposing a lot of additional
setup steps. It is largely automated and you're only going to have
to set it up once. It should take 30 minutes tops, and can easily be
done in less than 10.
(E) PostgreSQL is likely to be more acceptable in larger corporate
environments than sqlite, since while it is an AWESOME library, it is
generally not something you see behind larger web applications, and
this could discourage users.
(F) The big one -- Access control. It is important that multiple
users be able to share access to ansible, but /not/ have free reign on
the entire database. For instance, it may be possible to give
someone access to manage what their SSH keys can manage, but *NOT*
give them access to edit inventory. Since the inventory plugin must
be run by those users, they must at least have read access on the
database but not write access. Many users would like to control
access for users via things like LDAP, AD, etc -- and would not want
to have to enforce this via filesystem ACLs and permissions. This is
the primary reason we are doing this.
--Michael