Commit Graph

790 Commits

Author SHA1 Message Date
Wayne Witzel III
17e9b3057e Clean-up intiail commit for Host filter / DynamicInventory 2017-05-01 12:55:42 -04:00
Matthew Jones
e1e83598e9 Merge branch 'release_3.1.3' into devel
* release_3.1.3: (52 commits)
  ack fact scan messages
  making ldap user/group search fields into codemirror instances
  removing UI parsing for LDAP User and Group Search fields
  Allow exception view to accept all valid HTTP methods.
  Restore ability of parsing extra_vars string for provisioning callback.
  Fix up backup/restore role broken in f7a8e45809758322d9ee41c5305850dd70ed5faf
  Stop / start ansible-tower-service during restores
  value_to_python should encode lookup fields as ascii
  fix brace interpolation on standard out pane
  Adjust some hardcoded usages of 'awx' to use 'aw_user' and 'aw_group'.
  Pull Spanish updates from Zanata
  Temporarily grant awx user createdb role
  Stop giving ownership of backups to postgres
  don't display chunked lines'
  Add dropdown li truncation with ellipsis
  CTiT -> adhoc modules should allow the user to add new modules
  Remove task that was replacing the supervisor systemd tmp file
  Fix failing supervisorctl commands on RH-based distros
  Give ownership of the supervisor socket to awx
  Setting for external log emissions cert verification
  ...
2017-04-28 13:57:04 -04:00
Aaron Tan
0dc6bbe5a0 Prevent workflow resources from returning 402 with basic license. 2017-04-27 16:50:16 -04:00
Ryan Petrello
7037daa799 Merge pull request #6096 from ryanpetrello/api_new_in_v2
refactor API v2 version detection
2017-04-25 10:48:00 -04:00
Ryan Petrello
f0f859f553 Merge pull request #6088 from ryanpetrello/v1_custom_credentials
for /api/v1/ requests, filter out v2 (custom) credentials
2017-04-25 10:30:02 -04:00
Ryan Petrello
80df1523b0 refactor API v2 version detection and feature inclusion 2017-04-25 09:35:03 -04:00
Alan Rominger
34b697ce17 Fix 500 error in ProjectScmInventorySources 2017-04-24 16:54:17 -04:00
Ryan Petrello
83dc4f6757 for /api/v1/ requests, filter out v2 (custom) credentials
see: #5877
2017-04-24 15:21:30 -04:00
Ryan Petrello
7e64a6fd60 add "added_in_api_version" metadata to OPTIONS requests 2017-04-21 15:42:27 -04:00
Ryan Petrello
ba259e0ad4 Introduce a new CredentialTemplate model
Credentials now have a required CredentialType, which defines inputs
(i.e., username, password) and injectors (i.e., assign the username to
SOME_ENV_VARIABLE at job runtime)

This commit only implements the model changes necessary to support the
new inputs model, and includes code for the credential serializer that
allows backwards-compatible support for /api/v1/credentials/; tasks.py
still needs to be updated to actually respect CredentialType injectors.

This change *will* break the UI for credentials (because it needs to be
updated to use the new v2 endpoint).

see: #5877
see: #5876
see: #5805
2017-04-21 15:42:26 -04:00
Chris Meyers
a64f8a7660 Merge pull request #6045 from chrismeyersfsu/fix-hosts_list
return count, results, next, prev
2017-04-18 09:08:05 -04:00
Chris Meyers
70a8ccef0f return count, results, next, prev
* This returns /api/vx/hosts/ to having all the nice response items like
count, results, next, prev. I had "chopped" that off by explicitly only
returning result.
2017-04-17 16:43:29 -04:00
AlanCoding
6d92c56da5 SCM Inventory model, view, and task system changes
Inventory source file-type combined with a linked project
will allow the inventory source to be updated when the
project is updated. The inventory update runs in the
post-run hook of the project update.
2017-04-17 15:01:19 -04:00
Chris Meyers
2c34aef661 Merge pull request #6041 from chrismeyersfsu/feature-jsonsearch
remove facts_latest in favor of ansible_facts
2017-04-17 14:52:02 -04:00
Chris Meyers
55268a8ff0 remove facts_latest in favor of ansible_facts
* Closer align our facts data structure with ansible facts data
structure for purposes of ... wait for it ... 2-way fact caching
2017-04-17 14:27:33 -04:00
Chris Meyers
880f4a77a4 Merge pull request #6036 from chrismeyersfsu/fix-hosts_v2
run host listing through v1 vs. v2 logic
2017-04-17 12:12:24 -04:00
Chris Meyers
775093294e run host listing through v1 vs. v2 logic
* api/v1/hosts related fields were getting v2 in the related urls. The
context is now included in the serializer instantiation.
2017-04-17 11:43:44 -04:00
Alan Rominger
14a03d2cb5 Merge pull request #6029 from AlanCoding/group_v1
Group serializer special v1 functionality
2017-04-17 11:37:26 -04:00
AlanCoding
7223177684 Group serializer special v1 functionality
Returns a related `inventory_source` and related link for groups
if accessed from /api/v1/, but not for API v2.
Also inserts corresponding fields to inventory source serializer.
Keep migrated manual sources and auto-create in API v1.
2017-04-17 10:30:07 -04:00
Chris Meyers
bd1f8b088f 400 on invalid host filter query instead of 500 2017-04-13 09:40:11 -04:00
Wayne Witzel III
91f3e665cb group -> deprecated_group, added migrations, added/removed tests 2017-04-11 14:09:04 -04:00
Wayne Witzel III
7458788562 More updates for InventorySource changes 2017-04-11 14:04:25 -04:00
Matthew Jones
ea8b78ca49 Protect cluster nodes after an upgrade
* Modify instance model to container a version number for the node
* Update that version number during the heartbeat
* If during a heartbeat any of the nodes are of a newer version then
  shutdown the current node.

The idea behind this is that if all nodes were upgraded at the same
time then at the moment of the healthcheck they should all be at the
newer version. Otherwise we put the system in a state where it can
receive the upgrade but stay down until that happens. During setup
playbook run the services will be fully restarted.
2017-04-10 15:37:33 -04:00
Chris Meyers
ee09bca558 change facts_recent to facts_latest 2017-04-05 16:50:38 -04:00
Chris Meyers
f7fb541fe2 add facts recent endpoints
* Hang most recent listing of facts per-host off of /hosts/n/
2017-04-04 17:54:02 -04:00
Chris Meyers
a8213661fd basic fact search grammar
* Establish a base grammar for handling json path specification and
value matching. With boolean logic support and parenthesis grouping
i.e. (a.b.c="value") and ((a.b="foo") or (a="bar"))
* generate Q() results for passing to Host.objects.filter()
* Hooked up via /api/v1/hosts?host_filter=...
* DynamicFilterField added to store host filter as string with grammar
parser attached as static methods for later use by DynamicInventory &
continued use by host_filter=...
2017-04-03 15:32:21 -04:00
Ryan Petrello
95ea370e5e add API versioning for /api/v2/ 2017-03-30 15:11:12 -04:00
Ryan Petrello
ba0e9ab775 copy extra_vars when relaunching ad-hoc commands
see: #1744
2017-03-21 09:45:30 -04:00
Aaron Tan
2edd4b338d Add functional test to gurarantee consistent behavior of provisioning callback with jt launch. 2017-03-17 15:40:55 -04:00
Aaron Tan
6083e9482e Refactor job template callback post to mimic the behavior of normal jt launch. 2017-03-17 13:04:45 -04:00
Chris Meyers
1fc40d38c7 jobs/<id>/job_events?search= searches stdout field 2017-03-07 16:48:48 -05:00
Wayne Witzel III
c919f1ef30 Merge pull request #5487 from wwitzel3/issue-5341
explicit ordering in workflow_nodes views
2017-02-27 10:06:58 -05:00
Wayne Witzel III
a04411817f refactor based on review 2017-02-24 17:12:40 -05:00
Aaron Tan
f11a220e64 Add missing permission check. 2017-02-24 17:06:57 -05:00
Aaron Tan
2c4a16369d Restore original behavior of group children unattach. 2017-02-23 16:53:16 -05:00
Wayne Witzel III
87e0c9020f explicit ordering in workflow_nodes views 2017-02-21 02:33:45 -05:00
Ryan Petrello
e36cd17c16 fix a minor bug in survey_spec password field handling
see: #5477
2017-02-20 16:50:07 -05:00
Wayne Witzel III
a55e79e94d make OrderingFilter part of our default filters 2017-02-17 16:16:28 -05:00
Alan Rominger
68fc75070d Merge pull request #5348 from AlanCoding/dual_jt_count
Update organization counts to correspond with UI lists
2017-02-17 10:13:10 -05:00
Wayne Witzel III
a44fc6847c Merge pull request #5375 from wwitzel3/issue-5341
Ensure WorkflowJobWorkflowNodesList orders correctly, default by PK
2017-02-16 01:25:09 -05:00
Wayne Witzel III
cd35d64118 Ensure WorkflowJobWorkflowNodesList orders correctly, default by PK 2017-02-15 06:53:20 -05:00
AlanCoding
d054f86652 update organization counts to correspond with UI lists 2017-02-14 14:05:23 -05:00
Ryan Petrello
cae8950723 don't cache social-auth-core backends
social-auth-core uses a global variable to cache backend settings:
78da4eb201/social_core/backends/utils.py (L9)

when loading backends, forcibly ignore this behavior to avoid
a thread-safety issue that causes #4788 #4045
2017-02-14 11:35:42 -05:00
Alan Rominger
1651f62a76 Merge pull request #5192 from AlanCoding/signal_start_kwargs
Simplify use of signal_start
2017-02-06 11:15:11 -05:00
AlanCoding
32a7d46ac1 do not pass detailed kwargs into signal_start 2017-02-06 10:24:10 -05:00
Alan Rominger
b8aa1bd76e Merge pull request #5191 from AlanCoding/UJT_capability_prefetch
Unified Job Template user_capability prefetch + listview optimizations
2017-02-06 10:18:26 -05:00
AlanCoding
7967cc7722 force UJT user_capabilities to be correct for all submodels 2017-02-05 08:07:36 -05:00
AlanCoding
eb3b9d96ac prefetch labels 2017-02-03 22:55:34 -05:00
AlanCoding
da887241aa allow JT start on callback if mandatory survey variables are there 2017-02-03 20:29:28 -05:00
AlanCoding
914288c982 adapt the capabilities_prefetch to work with unified models 2017-02-03 15:59:35 -05:00