1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-02 09:51:09 +03:00
Commit Graph

23 Commits

Author SHA1 Message Date
cclauss
2e623ad80c Change unicode() --> six.text_type() for Python 3 2018-02-11 21:09:12 +01:00
cclauss
c371b869dc basestring to six.string_types for Python 3 2018-02-09 16:28:36 +01:00
AlanCoding
41940687f1
Pass existing object references within access methods
This avoids re-loading objects from the database in our
chain of permission checking, wherever possible.
access.py is equiped to handle object references instead
of pk ints, and permissions.py is changed to pass those refs.
2017-09-06 16:34:00 -07:00
Ryan Petrello
39525316ac prefix all /api/v1/ view descriptions with a deprecation message
additionally, fix a bug in /api/v1/credentials/ view descriptions that
causes v2 fields to display (see: #6116)
2017-06-21 16:27:07 -04:00
Chris Church
b6e2e3da70 Add new ansi_download format to download stdout and preserve ANSI escape sequences. 2016-12-15 16:03:00 -05:00
Matthew Jones
30984a3a79 Fix up flake8 errors 2016-11-10 13:07:48 -05:00
Matthew Jones
1a3d452a2d Fix an auth issue in the browsable api
Trying to get the object could raise an unhandleable permission error if
the user wasn't logged in for certain views
2016-11-10 11:46:25 -05:00
Chris Church
6ebe45b1bd Configure Tower in Tower:
* Add separate Django app for configuration: awx.conf.
* Migrate from existing main.TowerSettings model to conf.Setting.
* Add settings wrapper to allow get/set/del via django.conf.settings.
* Update existing references to tower_settings to use django.conf.settings.
* Add a settings registry to allow for each Django app to register configurable settings.
* Support setting validation and conversion using Django REST Framework fields.
* Add /api/v1/settings/ to display a list of setting categories.
* Add /api/v1/settings/<slug>/ to display all settings in a category as a single object.
* Allow PUT/PATCH to update setting singleton, DELETE to reset to defaults.
* Add "all" category to display all settings across categories.
* Add "changed" category to display only settings configured in the database.
* Support per-user settings via "user" category (/api/v1/settings/user/).
* Support defaults for user settings via "user-defaults" category (/api/v1/settings/user-defaults/).
* Update serializer metadata to support category, category_slug and placeholder on OPTIONS responses.
* Update serializer metadata to handle child fields of a list/dict.
* Hide raw data form in browsable API for OPTIONS and DELETE.
* Combine existing licensing code into single "TaskEnhancer" class.
* Move license helper functions from awx.api.license into awx.conf.license.
* Update /api/v1/config/ to read/verify/update license using TaskEnhancer and settings wrapper.
* Add support for caching settings accessed via settings wrapper.
* Invalidate cached settings when Setting model changes or is deleted.
* Preload all database settings into cache on first access via settings wrapper.
* Add support for read-only settings than can update their value depending on other settings.
* Use setting_changed signal whenever a setting changes.
* Register configurable authentication, jobs, system and ui settings.
* Register configurable LDAP, RADIUS and social auth settings.
* Add custom fields and validators for URL, LDAP, RADIUS and social auth settings.
* Rewrite existing validator for Credential ssh_private_key to support validating private keys, certs or combinations of both.
* Get all unit/functional tests working with above changes.
* Add "migrate_to_database_settings" command to determine settings to be migrated into the database and comment them out when set in Python settings files.
* Add support for migrating license key from file to database.
* Remove database-configuable settings from local_settings.py example files.
* Update setup role to no longer install files for database-configurable settings.

f 94ff6ee More settings work.
f af4c4e0 Even more db settings stuff.
f 96ea9c0 More settings, attempt at singleton serializer for settings.
f 937c760 More work on singleton/category views in API, add code to comment out settings in Python files, work on command to migrate settings to database.
f 425b0d3 Minor fixes for sprint demo.
f ea402a4 Add support for read-only settings, cleanup license engine, get license support working with DB settings.
f ec289e4 Rename migration, minor fixmes, update setup role.
f 603640b Rewrite key/cert validator, finish adding social auth fields, hook up signals for setting_changed, use None to imply a setting is not set.
f 67d1b5a Get functional/unit tests passing.
f 2919b62 Flake8 fixes.
f e62f421 Add redbaron to requirements, get file to database migration working (except for license).
f c564508 Add support for migrating license file.
f 982f767 Add support for regex in social map fields.
2016-09-26 22:14:47 -04:00
Chris Church
4873e2413f * Populate browsable API raw data form with submitted request data in response to an update.
* Remove fields from browsable API raw data that are set implicitly based on URL / parent object.
* Fix issue where a group/host could be assigned to a different inventory.
* Update validation to load values from existing instance if not present in new data; allows PATCH requests to succeed.
* Remove job_args, job_cwd, job_env, result_stdout and result_traceback fields from job listings.
2016-02-16 17:49:34 -05:00
Chris Church
60224cdbe4 Update Django to 1.8 and DRF to 3.3, add new Django migrations, update serializers/pagination/metadata, update browsable API styling. 2016-02-02 17:48:04 -05:00
Matthew Jones
c231601b76 Fix merge issues on stdout branch
The act of committing a PR that including part of these changes and then
reverting it meant that some of the changes from the original branch
didn't land in this new PR.   This commit adds the missing bits.

Lesson learned:  Create a new branch when submitting a PR on a
previously reverted PR
2015-08-04 09:57:39 -04:00
Matthew Jones
5df23b95f6 Revert "Improve stdout behavior by implementing a downloadable stdout." 2015-07-24 14:54:13 -04:00
Matthew Jones
0ff280a363 Initial support for downloading stdout 2015-07-22 12:36:38 -04:00
John Mitchell
32d1c0e4db fixed copyright date 2015-06-11 16:10:23 -04:00
Matthew Jones
b3da3b34a3 Changing some legal headers for python source files 2015-05-29 12:10:39 -04:00
Matthew Jones
bb3732b2c1 Cleaning up some flake8 errors, pyflakes in this case 2015-02-10 17:00:23 -05:00
Matthew Jones
6e6a709165 Fixing up some pep8 issues 2015-02-03 13:46:58 -05:00
Chris Church
4f74afdf19 Add response headers for timing API requests, improve inventory script view performance. 2014-05-14 13:52:46 -04:00
Chris Church
d632aa0af9 Only show editable fields in the browsable API raw data form on a detail view. 2014-04-01 21:10:16 -04:00
Chris Church
0b3d056c16 Always use JSON renderer for OPTIONS requests in browsable API, override default renderer. 2014-04-01 20:51:15 -04:00
Chris Church
86599cf1e3 Add API resource for unified job stdout with HTML output of ANSI color codes. 2014-04-01 20:15:43 -04:00
Chris Church
2b7af0a2ec Happy new year!!! 2014-01-02 11:51:43 -05:00
Chris Church
98883e771f Moved API code into separate Django app. 2013-11-04 15:44:49 -05:00