Commit Graph

1618 Commits

Author SHA1 Message Date
AlanCoding
37f9024940 fix slicing task_impact and script gen bugs 2018-10-31 11:04:13 -04:00
AlanCoding
6dc58af8e1 slicing rename test cleanup and bugfix 2018-10-31 11:04:12 -04:00
AlanCoding
bbd3edba47 rename to slicing and schema tweaks 2018-10-31 11:04:12 -04:00
Matthew Jones
46d6dce738 Mass rename of shard -> split 2018-10-31 11:04:12 -04:00
AlanCoding
475a701f78 Allow use of credential password prompting with split JTs
also
*update test to work with new JT callback call pattern
*fix spelling in template
2018-10-31 11:04:11 -04:00
AlanCoding
20226f8984 Polish split jobs API info & add fields to UI
*clarify help text and squash migrations
*adds new internal_limit field to Job model for faster reference
*if field is non-blank, populate shard params in summary_fields
*add summary information to UI job/wfj details, JT selector
2018-10-31 11:04:10 -04:00
AlanCoding
7ff04dafd3 Fix IntegrityError deleting job splitting JT
misc:
*show sharded jobs in recent_jobs
*test updates
2018-10-31 11:04:10 -04:00
AlanCoding
f9bdb1da15 Job splitting access logic and more feature development
*allow sharding with prompts and schedules
*modify create_unified_job contract to pass class & parent_field name
*make parent field name instance method & set sharded UJT field
*access methods made compatible with job sharding
*move shard job special logic from task manager to workflows
*save sharded job prompts to workflow job exclusively
*allow using sharded jobs in workflows
2018-10-31 11:04:10 -04:00
AlanCoding
dab678c5cc Implement splitting logic in inventory & job task code 2018-10-31 11:04:10 -04:00
Matthew Jones
44ffcf86de Properly take prompted inventory into account
This also will rename shard jobs to add an index to the job name
2018-10-31 11:04:10 -04:00
Matthew Jones
8a18984be1 Spawn concrete workflow jobs from a job template launch 2018-10-31 11:04:09 -04:00
Matthew Jones
0b1776098b Implement model/view/launch paradigm for shard/split job templates 2018-10-31 11:04:09 -04:00
AlanCoding
526ca3ae42 automatically delete project files in entire cluster 2018-10-25 16:36:58 -04:00
AlanCoding
8965f1934e fix bug with relaunching with changed JT 2018-10-25 11:45:47 -04:00
Ryan Petrello
c695ba2e10 fix flake8 2018-10-24 10:11:53 -04:00
Ryan Petrello
3be9113d6b fix a bug that breaks job cancel on single node jobs
1.  Install awx w/ a single node.
2.  Start a long-running job.
3.  Forcibly kill the `awx-manage run_dispatcher` process (e.g.,
    SIGKILL) and do not start it again.
4.  The job remains in running - without a second cluster to discover
    the job, it is never reaped.
5.  This PR allows you to cancel the job from the UI+API.
2018-10-19 09:10:33 -04:00
Matthew Jones
0477581dea Fix up flake8 2018-10-16 11:30:07 -04:00
Matthew Jones
8e60cb1270 Purge an unneeded ansible 2.4 version check 2018-10-16 11:30:05 -04:00
Ryan Petrello
ff1e8cc356 replace celery task decorators with a kombu-based publisher
this commit implements the bulk of `awx-manage run_dispatcher`, a new
command that binds to RabbitMQ via kombu and balances messages across
a pool of workers that are similar to celeryd workers in spirit.
Specifically, this includes:

- a new decorator, `awx.main.dispatch.task`, which can be used to
  decorate functions or classes so that they can be designated as
  "Tasks"
- support for fanout/broadcast tasks (at this point in time, only
  `conf.Setting` memcached flushes use this functionality)
- support for job reaping
- support for success/failure hooks for job runs (i.e.,
  `handle_work_success` and `handle_work_error`)
- support for auto scaling worker pool that scale processes up and down
  on demand
- minimal support for RPC, such as status checks and pool recycle/reload
2018-10-11 10:53:30 -04:00
AlanCoding
a4dfd96a8d Validate ANSIBLE_ injectors on save and increase verbosity 2018-10-09 13:46:51 -04:00
Ryan Petrello
2acc488adf properly sanitize long event keys
see: https://github.com/ansible/tower/issues/1775
2018-08-27 13:40:26 -04:00
Ryan Petrello
67d1267d98 enforce 0 <= Instance.capacity_adjustment
see: https://github.com/ansible/tower/issues/2839
2018-08-21 15:34:19 -04:00
Alan Rominger
598449c2ce Merge pull request #2882 from AlanCoding/just_credential2
[option2] move inventory source vault credential validation from view to model
2018-08-21 13:24:50 -04:00
Ryan Petrello
4eeb62766e apply sensitive field filtering to /api/v2/hosts/?host_filter
see: https://github.com/ansible/tower/issues/2874
see: https://github.com/ansible/tower/issues/2889
2018-08-21 08:17:14 -04:00
AlanCoding
9a85578925 move inv src vault cred validation from view to model 2018-08-20 08:53:55 -04:00
AlanCoding
a99ebbb02f Apply policy task more selectively 2018-08-03 06:56:15 -04:00
Alan Rominger
9ff249f5c4 Merge pull request #2438 from AlanCoding/ask_user_input_creds
Ask user input if credential prompting enabled
2018-07-31 15:48:19 -04:00
Yunfan Zhang
9cdee4f75c Merge pull request #2711 from YunfanZhang42/add_instance_groups_to_activity_stream
Add instance groups to activity stream.
2018-07-31 13:17:22 -04:00
Yunfan Zhang
f9309c9cd9 Add instance groups to activity streams.
Signed-off-by: Yunfan Zhang <yz322@duke.edu>
2018-07-31 11:01:29 -04:00
Ryan Petrello
3cdd0a94bd simplify dynamic queue binding
we recently made a change so that instances no longer bind to
instance-group specific queues, but now instead they each bind to
a direct queue for their specific hostname
(https://github.com/ansible/tower/pull/1922)

Because of this, we shouldn't *need* to reconfigure the queue binds at
runtime anymore when group membership changes. Under our new model,
every celeryd listens on a queue named after its hostname; when the
scheduler finds a task to run, it picks an Instance in the target
Instance Group and sends the task to the queue for that Instance's
hostname.
2018-07-28 00:48:37 -04:00
Christian Adams
0694fa83b0 Merge pull request #2682 from rooftopcellist/remove_client_credentials
Remove Client Credentials grant_type
2018-07-26 10:18:46 -04:00
adamscmRH
87829ea339 remove client credentials grant_type 2018-07-25 18:23:08 -04:00
Ryan Petrello
15aaca8f03 make InstanceGroup.policy_instance_list non-exclusive by default
see: https://github.com/ansible/tower/issues/2583
2018-07-25 17:26:13 -04:00
AlanCoding
fa3a334424 Handle does not exist errors in JobHostSummary unicode 2018-07-23 10:17:47 -04:00
Alan Rominger
5c7c441b47 Merge pull request #2555 from AlanCoding/app_name_unique
Make applications org-name-unique
2018-07-17 16:49:57 -04:00
Jake McDermott
a968a44afb add inventory field to inventory update 2018-07-17 11:10:06 -04:00
AlanCoding
885ea2c5e1 make applications name-unique 2018-07-16 15:54:00 -04:00
Ryan Petrello
ca6b6460bb Merge pull request #2522 from ryanpetrello/fix-2509
awx metavars for job.created_by should be more robust to DoesNotExist
2018-07-16 12:46:50 -04:00
Ryan Petrello
55be530e27 awx metavars for job.created_by should be more robust to DoesNotExist
see: https://github.com/ansible/tower/issues/2509
2018-07-16 11:35:35 -04:00
AlanCoding
e897cbd237 fix unicode bug in launch error message 2018-07-13 15:50:50 -04:00
Ryan Petrello
df0e28ec65 don't allow OAuth2 token creation for "external" users
see: https://github.com/ansible/tower/issues/2326
2018-07-12 14:33:59 -04:00
Alan Rominger
f268857129 Merge pull request #2466 from AlanCoding/prompts_but_not_prompts
Fix regression of JT callback relaunch
2018-07-11 13:58:39 -04:00
AlanCoding
6697d0c205 fix bug where empty extra vars gave relaunch 500 2018-07-11 13:09:44 -04:00
Yunfan Zhang
e2ed24aef0 Fix null values on Token modified field. 2018-07-10 16:03:25 -04:00
Ryan Petrello
acd045379c Revert "enforce JT/Job.timeout >= 0"
This reverts commit 1fb41cf8d0.
2018-07-10 15:06:13 -04:00
AlanCoding
ec643d6406 fix regression of callback relaunch 2018-07-10 08:45:23 -04:00
Ryan Petrello
1fb41cf8d0 enforce JT/Job.timeout >= 0
see: https://github.com/ansible/tower/issues/2421
2018-07-10 08:25:36 -04:00
AlanCoding
e044b996e5 allow adding teams to org object roles 2018-07-09 14:13:57 -04:00
Wayne Witzel III
8969276710 Merge pull request #2446 from ansible/issue-2330
Add explicit Job Template Admin role
2018-07-09 13:26:39 -04:00
Jake McDermott
3b3ae9f7f5 Merge pull request #2444 from jakemcdermott/fix-2334
add host_status_counts to adhoc commands; fix status display for adhoc commands
2018-07-09 12:08:25 -04:00