Commit Graph

17 Commits

Author SHA1 Message Date
Mike Terzo
faac5fa1bc Travis ci integration (#267)
* Initial travis-ci integration

* Format code base to PEP8
2016-07-13 20:59:07 -04:00
Corey Hammerton
59c79c7592 Puppetboard: Version Bump to 0.2.0 (#263) 2016-06-28 20:42:44 -04:00
Corey Hammerton
da044271ee PuppetBoard: Upgrading WTForms to latest version and restoring CSRF Protection (#250)
Upgrading the following packages to the respected versions:

WTForms==2.1
Flask-WTF==0.12
Werkzeug==0.11.0

Passing newly required metadata to the QueryForm constructor in puppetboard/app.py

Apache >= 2.4 with mod_wsgi experienced a major issue where it would re-generate
the app's secret key on each request. The fix for this turned out to be placing
a permanent statis 'secret_key' value in the wsgi.py. Adding a block in README.rst
on how to implement the user's own secret_key
2016-06-23 20:32:31 -04:00
Corey Hammerton
adac2a46bf Implementing new pypuppetdb.QueryBuilder (#251)
* puppetboard/app.py: Implementing and utilizing the new PyPuppetDB QueryBuilder

This fixes https://github.com/voxpupuli/puppetboard/issues/239

Replacing all the directly declared query strings with various objects
from the pypuppetdb.QueryBuilder sub-module. Using this Object-Oriented
functionality it is programmatically safer to construct large, complex
queries.

* puppetboard/app.py: Simplifying the environment logic in `node()`

The query in this function will now always be an `AndOperator()` object.
If a specific environment is queried then that constraint is added.

The resulting query difference will be:

env == 'production'

`["and",["=", "environment", "production"],["=", "certname", "puppet01.hammertime.local"]]`

env == '*'

`["and",["=", "certname", "puppet01.hammertime.local"]]`

* puppetboard/app.py: Minor code simplification for more accurate results.

In index() adding the configured OVERVIEW_FILTER query after adding the previous
constraints to num_nodes_query
In inventory() wrapping fact_query in an AndOperator() regardless of environment.
This update makes it more common with other endpoints that only add environment
constraints if an environment is selected.

* requirements.txt: Bumping the pypuppetdb version requirement

* requirements.txt: Bumping pypuppetdb version to new requirement.

* puppetboard/app.py: Fixing module load error.
2016-06-23 20:26:21 -04:00
Vadym Chepkov
b1a3d203a3 update links to github Puppet Community 2016-06-04 10:17:51 -04:00
corey.hammerton
c80da7192d Version bump to 0.1.3 2016-03-21 20:31:45 -04:00
corey.hammerton
c13389cc3e Version bump to 0.1.2 2016-02-15 19:57:43 -05:00
Corey Hammerton
43e37fdf64 Using new Node and Catalog fields available in pypuppetdb 0.2.1
Showing the Code ID field in the catalogs page. This is currently
unused in PuppetDB as of 3.2.2 but may be useful when it will be used

If available, using the latest_report_hash field of the node object
in the index and nodes templates for the link to the latest report
available for the node.

Updating the report_latest function in app.py to query the nodes
endpoint and redirecting using the latest_report_hash field if available.
If not query the reports endpoint for the node's latest report.
2015-12-28 16:07:43 -05:00
Corey Hammerton
8b0a797097 puppetboard/setup.py: Version bump 2015-11-12 19:50:28 -05:00
Corey Hammerton
af05f67428 puppetboard: Adding PuppetDB 3.x support
Some excerpts from CHANGELOG.rst include:
- Increasing the pypuppetdb requirements from 0.1.x to 0.2.x
- The Reports page now lists reports from the reports endpoint instead of
  a link to a PuppetDB issue with a feature request
- Adding a Catalogs page to view either individual node catalogs or compare
  them against other nodes
- New environment awareness adds a new query parameter to all applicable
  endpoints to filter results based on the current environment. If the
  default environment 'production' is not available, or any other unavailable
  environment, the user is redirected to the first known environment.
- Adding pagination functionality for reports (for now) based on the value of
  the REPORTS_COUNT configuration option (used for the limit and the offset
  calculation). Implementation also makes it possible for other UI enhancements.
- Removing the limit_reports function from puppetboard/utils.py since paging
  parameters are now accepted by the pypuppetdb endpoint functions.
- Bumping the version to 0.1.0
2015-10-26 21:44:33 -04:00
Corey Hammerton
0e0c46d17c setup.py: Requiring pypuppetdb >= 0.1.0
In addition to requiring pypuppet in versions less than 0.2.0 we also need versions greater than or equal to 0.1.0 because they support the Query API v3.
2015-10-15 20:42:44 -04:00
Corey Hammerton
9fbd283c9f puppetboard: Version bump to 0.0.5 2015-10-09 20:22:37 -04:00
Daniele Sluijters
a1160d2c1f setup: Pin version requirements of WTForms.
Mentions: #124
2015-03-04 17:58:37 +01:00
Daniele Sluijters
693763d03d setup: We now support Python 3 too! 2014-03-13 12:05:19 +01:00
Daniele Sluijters
aabd82a08e setup: Bump to 0.0.4. 2014-01-21 15:13:02 +01:00
Daniele Sluijters
c52da03f60 setup: Fix your license so bdist_rpm doesn't trip. 2014-01-21 15:12:40 +01:00
Daniele Sluijters
c6b194ca83 Add setup.py|cfg and MANIFEST.in for packaging. 2014-01-16 11:31:49 +01:00