603 Commits

Author SHA1 Message Date
Alan Rominger
dd977c608b Merge pull request #1279 from AlanCoding/822_keystone_v3_OS_cred
Add OpenStack V3 credential type
2016-03-23 16:45:42 -04:00
Matthew Jones
7f8fae566e Further decouple survey spec from enablement
We now show the survey summary field only if the contents of the survey
spec or valid (not the default {})
2016-03-22 14:59:56 -04:00
AlanCoding
c807d5dcf3 Add keystone v3 support via new domain field on credential 2016-03-18 16:41:09 -04:00
Matthew Jones
526a6ec7dd Remove unneeded fetch for r/o fields 2016-03-16 13:12:13 -04:00
Matthew Jones
45f95bf2b2 Disallow related elements to be treated as choices
DRF will try to resolve potential candidates into the OPTIONS endpoint.
This is mainly to support their POST field in the browseable API.   We
don't need this and it can yield some expensive queries so we bypass
generating choices for any RelatedField fields
2016-03-16 13:11:05 -04:00
AlanCoding
da39f1269a org counts code restructing to better prepare for RBAC merge 2016-03-15 14:36:56 -04:00
AlanCoding
6996ea22b0 style tweaks, add one more assertion 2016-03-13 22:39:52 -04:00
AlanCoding
39c9563352 test and fix for POST to empty list scenaro and JT count fix 2016-03-13 20:40:21 -04:00
AlanCoding
9f25a48936 fix for POST scenario 2016-03-13 11:45:08 -04:00
AlanCoding
765dcd3318 Added queries that calculate counts for organization resources 2016-03-12 22:02:03 -05:00
Matthew Jones
eab223d229 Make sure we are covering system jobs and template on notifications 2016-03-11 15:11:08 -05:00
Matthew Jones
c2ea9c3c00 Make survey always visible if license enables
Previously this would only be visible if survey is enabled.  It should
be possible to define and view a survey even if this is disabled.   The
enablement flag controls whether the survey prompt is shown and required.
2016-03-10 16:09:34 -05:00
Chris Meyers
3d963d540f remove the starting of mongo 2016-03-09 15:40:09 -05:00
Chris Church
60b6b6bfea Fix job template callback view to accept URL-encoded form data. 2016-03-04 16:36:02 -05:00
Chris Meyers
cfeae51254 deny endpoint access to system tracking feature based on license 2016-03-04 10:14:13 -05:00
Matthew Jones
1f19c13ac9 Fix up a Notification unit test issue after the merge 2016-03-01 12:16:10 -05:00
Chris Meyers
356b9c99b3 Merge branch 'mongoectomy_implementation' into devel 2016-03-01 08:22:40 -05:00
Matthew Jones
99ec07b8a5 Merge branch 'notifications_work' into devel
* notifications_work: (23 commits)
  Updates to notification unit tests after @wwitzel3's feedback
  Fix some notifications issues and write some tests
  Add notification system documentation
  Clean up flake8 related issues
  Fixing up some unicode issues
  Implement tower ui view url on models
  Sanity check and force proper types in admin check
  Proper type for in check
  Adding migration and base notification type
  Add a periodic administrative notification
  Refactor message generator
  Support notification password field encryption
  Notification configuration type checking
  Refactor NotificationTemplate to Notifier
  Implement irc notification backend
  Add webhook notification backend
  Pagerduty and Hipchat backends plus some cleanup
  Notification serializers, views, and tasks
  Implement notification serializer and validations
  Notification endpoints and url expositions
  ...
2016-02-29 16:50:33 -05:00
Matthew Jones
a9bf29d2a7 Add the id field to the default summary fields
This is to support the UI.

ref: #1063
2016-02-26 11:30:34 -05:00
Chris Church
a2595dcf12 API fixes for 500 errors. 2016-02-24 18:38:04 -05:00
Chris Church
5b89c5e126 Merge pull request #1016 from cchurch/fix-job-template-launch-fields
Remove write-only fields from GET response for job template launch.
2016-02-24 18:12:47 -05:00
Chris Meyers
7ffe46fc74 add postgres Fact model, update views, tests
* awx.main.models Fact added
* view host fact and timeline updated to use new Postgres Fact model instead of Mongo
* Removed license set start Mongo logic
* added View tests
* added Model tests
* Removed mongo fact unit tests
* point at modified jsonbfield that supports sqlite storage driver
* postgresify fact cache receiver
* test OPTIONS endpoint
* Note: single fact view not implemented yet.
2016-02-24 14:38:54 -05:00
Matthew Jones
41d5393af0 Clean up flake8 related issues 2016-02-23 15:30:07 -05:00
Matthew Jones
75ef0dd395 Implement tower ui view url on models 2016-02-23 14:19:42 -05:00
Chris Church
90d1a3d020 Remove write-only fields from GET response for job template launch, update raw data form to show any fields/passwords needed to launch the job. 2016-02-23 14:04:30 -05:00
Chris Meyers
cad54a43a1 Merge pull request #1001 from chrismeyersfsu/fix-options_choices
bring back meta choice options lost in upgrade
2016-02-23 13:55:53 -05:00
Chris Church
6f988452c3 Merge pull request #977 from cchurch/api-raw-data-form-fixes
API Raw Data Form & Validation Fixes
2016-02-23 12:23:14 -05:00
Matthew Jones
ab3669efa9 Refactor message generator
* Job object can now control the output and generate K:V output for
  notification types that can support it
* Notifications store the body as json/dict now to encode more
  information
* Notification Type can further compose the message based on what is
  sensible for the notification type
* This will also allow customizing the message template in the future
* All notification types use sane defaults for the level of detail now
2016-02-22 17:09:36 -05:00
Chris Meyers
d70615efbd bring back meta choice options lost in upgrade
* status and launch_type OPTIONS choices were lost in the django + drf
upgrade. This brings them back.
2016-02-22 12:58:35 -05:00
Matthew Jones
eb3d663d18 Support notification password field encryption
Modify encrypt_field and decrypt_field to support sub-fields under a
dictionary object.  It still uses the parent key when encrypting.
2016-02-21 23:11:17 -05:00
Matthew Jones
52974648df Notification configuration type checking 2016-02-17 16:01:54 +00:00
Matthew Jones
dde70dafec Refactor NotificationTemplate to Notifier 2016-02-17 15:18:18 +00:00
Chris Church
d8ae1115f0 Fix extra_vars/survey handling since request.data is now an OrderedDict. 2016-02-17 00:04:28 -05:00
Chris Church
99150b5a05 Flake8 fixes. 2016-02-16 20:02:52 -05: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
AlanCoding
33e84d03ef add job_template related list to inventory endpoint 2016-02-16 10:12:35 -05:00
Chris Church
dc298daeb4 Update settings serializer to allow empty/blank values. 2016-02-11 18:11:41 -05:00
Chris Church
a8fec62095 Flake8 fix. 2016-02-11 18:11:41 -05:00
Chris Church
1f290ed940 Add custom serializer char/bool fields to accept null and coerce to appropriate type. Update validation for unique constraints so that error messages remain the same as before. Update key used in error response for non-field errors. Should address #791, #794, #809, #812 and #816. 2016-02-11 18:11:41 -05:00
Matthew Jones
8db2f60405 Notification serializers, views, and tasks
* Implement concrete Notification model for notification runs
* Implement NotificationTemplate and Notification serializers and views
* Implement ancillary views
* Implement NotificationTemplate trigger m2m fields on all job templates
  via a fields mixin
* Link NotificationTemplates with an org
* Link notifications with the activity stream
* Implement Notification celery tasks
* Extend Backend field parameters to identify sender and receiver as
  parameters needed by the message and not the backend itself
* Updates to backends to better fit the django email backend model as it
  relates to Messages
* Implement success job chain task + notifications
* Implement notifications in error job chain task
2016-02-09 23:12:55 -05:00
Matthew Jones
a2cf365325 Merge pull request #804 from cchurch/allow-null-or-blank-for-project-booleans
Allow null/blank input for boolean fields on projects.
2016-02-05 09:55:15 -05:00
Matthew Jones
b8dfa3df16 Merge pull request #803 from cchurch/remove-fields-for-ad-hoc-commands
Remove unified_job_template and description fields for ad hoc commands
2016-02-05 09:55:06 -05:00
Matthew Jones
38b1d13edc Merge pull request #802 from cchurch/metadata-check-if-view-has-serializer
Check if view has a get_serializer method before trying to call it.
2016-02-05 09:54:59 -05:00
Chris Church
abc8da4531 Allow null/blank input for boolean fields on projects. Fixes #791. 2016-02-05 05:14:48 -05:00
Chris Church
da0f87c325 Remove unified_job_template and description fields for ad hoc commands. Fixes #789. 2016-02-05 04:55:40 -05:00
Chris Church
23feccdbf3 Check if view has a get_serializer method before trying to call it. Fixes OPTIONS issue in #788. 2016-02-05 04:45:14 -05:00
Chris Church
217fd383b3 Don't show playbooks under project detail. Fixes #792. 2016-02-05 04:09:17 -05:00
Matthew Jones
319deffc18 Implement notification serializer and validations 2016-02-04 15:52:23 -05:00
Matthew Jones
172207cd4b Notification endpoints and url expositions
Also some changes to the footprint of the notification handler classes
2016-02-04 15:52:23 -05:00
Chris Church
ab8e37eeaa Minor fixes based on comments. 2016-02-03 13:18:49 -05:00