Skip to content

Commit

Permalink
Mkdocs
Browse files Browse the repository at this point in the history
  • Loading branch information
fboender committed Apr 28, 2018
1 parent 7b94174 commit 1a81180
Show file tree
Hide file tree
Showing 6 changed files with 570 additions and 0 deletions.
46 changes: 46 additions & 0 deletions docs/dev.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
## Contributions

If you wish to contribute code, please consider the following:

* Code should be reasonably PEP8-like. I'm not too strict on this.
* One logical change per merge request.
* By putting in a merge request or putting code in comments, you automatically
grant me permission to include this code in ansible-cmdb under the license
(GPLv3) that ansible-cmdb uses. The copyright for contributed code is
retained by the contributor.
* Please don't be disappointed or angry if your contributions end up unused.
It's not that they aren't appreciated, but I can be somewhat strict when it
comes to code quality, feature creep, etc.

When in doubt, just open a pull request and post a comment on what you're
unclear of, and we'll figure it out.


# License

Ansible-cmdb is licensed under the GPLv3:

This program is free software: 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.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

For the full license, see the LICENSE file.

# History

Ansible-cmdb started as a short Python script, which I [blogged
about](http://www.electricmonk.nl/log/2015/01/21/host-inventory-overview-using-ansibles-facts/).

[Cris van Pelt](https://melkfl.es/) then took that and expanded it into a HTML
page. Eventually I forked it to Github and made it public, adding features.
[Many people collaborated](https://github.com/fboender/ansible-cmdb/graphs/contributors) to
make Ansible-cmdb into what it is today.
6 changes: 6 additions & 0 deletions docs/faq.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## Solaris machines have no disk information

Ansible currently does not include disk size information for Solaris hosts. As
such, we can't include it in the output of Ansible-cmdb. See issue #24 for more
information.

36 changes: 36 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## About

[Ansible-cmdb](https://github.com/fboender/ansible-cmdb) takes the output of
Ansible's [fact
gathering](http://docs.ansible.com/ansible/latest/modules/setup_module.html)
and converts it into a static HTML overview page (and other things) containing
system configuration information.

It supports multiple types of output (html, csv, sql, etc) and extending
information gathered by Ansible with custom data. For each host it also shows
the groups, host variables, custom variables and machine-local facts.

## Example output

![](https://raw.githubusercontent.com/fboender/ansible-cmdb/master/contrib/screenshot-overview.png)

![](https://raw.githubusercontent.com/fboender/ansible-cmdb/master/contrib/screenshot-detail.png)

[HTML example](https://rawgit.com/fboender/ansible-cmdb/master/example/html_fancy.html) output.

## Output formats

Supported output formats / templates:

* Fancy HTML (`--template html_fancy`), as seen in the screenshots above.
* Fancy HTML Split (`--template html_fancy_split`), with each host's details
in a separate file (for large number of hosts).
* CSV (`--template csv`), the trustworthy and flexible comma-separated format.
* JSON (`--template json`), a dump of all facts in JSON format.
* Markdown (`--template markdown`), useful for copy-pasting into Wiki's and
such.
* Markdown Split ('--template markdown_split'), with each host's details
in a seperate file (for large number of hosts).
* SQL (`--template sql`), for importing host facts into a (My)SQL database.
* Plain Text table (`--template txt_table`), for the console gurus.
* and of course, any custom template you're willing to make.
70 changes: 70 additions & 0 deletions docs/installation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
## Requirements

Ansible-cmdb requires **Python v2.7+ / 3.0+**.

In theory, it should work on any system that can run Python, including BSD,
Linux, Windows, Solaris and MacOS. In practice, ansible-cmdb is developed on
Ubuntu 16.04 and tested on the latest stable versions of Debian, Ubuntu and
Centos.

## Installation


Ansible-cmdb can be installed using `pip`, the [Python package
manager](https://pypi.org/project/pip/). There are also stand-alone packages
for various Linux distributions. Alternatively, you can use brew or plain old
`make install`.

### Through Pip

For **installation via Pip**:

Install `pip` [for your distribution](https://packaging.python.org/install_requirements_linux/)
if you don't have it yet.

Install Ansible-cmdb through Pip:

sudo pip install ansible-cmdb

You can also upgrade Ansible-cmdb through Pip:

sudo pip install --upgrade ansible-cmdb

### Through distribution packages

Get the package for your distribution from the [Releases
page](https://github.com/fboender/ansible-cmdb/releases) (Not required for
MacOS X install)

For **Debian / Ubuntu** systems:

sudo dpkg -i ansible-cmdb*.deb

For **Redhat / Centos** systems:

sudo yum --disablerepo=* install ansible-cmdb*.rpm

For **Arch** systems:

[aur/ansible-cmdb](https://aur.archlinux.org/packages/ansible-cmdb/), but it
is out-of-date.

### For other systems

For **MacOS X** systems:

brew install ansible-cmdb

For **Other** systems:

tar -vxzf ansible-cmdb*.tar.gz
cd ansible-cmdb*
sudo make install

Installation from **Git** repository:

git clone [email protected]:fboender/ansible-cmdb.git
cd ansible-cmdb
sudo make install


Loading

0 comments on commit 1a81180

Please sign in to comment.