Commit Graph
100 Commits
Author SHA1 Message Date
John Westcott IV 222e58dd34 Adding lookup to rrule plugin test logic for new tooling
This change is provided with the tower_api lookup plugin because the require tower_meta module is part of this commit
2020-07-14 09:38:26 -04:00
John Westcott IV 0be7d9b21a Removing redundant check 2020-07-14 09:38:26 -04:00
John Westcott IV 5a6c7a5788 Fixing copyrights and linting issues 2020-07-14 09:38:26 -04:00
John Westcott IV 3784f9515e More refinement of examples 2020-07-14 09:38:26 -04:00
John Westcott IV 6638d6c2bb Update examples 2020-07-14 09:38:26 -04:00
John Westcott IV afbdeb5ff8 Fixing linting errors 2020-07-14 09:38:26 -04:00
John Westcott IV 381e9d2901 Reverting commit 81b192c3b0520be0897f95e2630edab295e6bf24, we should fail only if we are > max_objects 2020-07-14 09:38:26 -04:00
John Westcott IV dd478af227 Overhaul of the testing suite 2020-07-14 09:38:26 -04:00
John Westcott IV 0424370d49 Revamp of the examples 2020-07-14 09:38:26 -04:00
John Westcott IV 1a4bb42ac5 When using return_ids send back a list of strings instead of ints.
When we used ints and passed this data into a nother call like:
    - name: Create a job template with a looked up credential from a folded lookup
      tower_job_template:
        name: "{{ job_template_name }}"
        credentials: >-
            {{ lookup(
                'awx.awx.tower_api',
                'credentials',
                query_params={ 'name' : credential_name },
                return_ids=True,
                expect_one=True,
                wantlist=True
            ) }}
        project: "{{ project_name }}"
        inventory: Demo Inventory
        playbook: hello_world.yml
        job_type: run
        state: present
      register: create_jt

Ansible would raise this warning:
[WARNING]: The value 30 (type int) in a string field was converted to '30' (type string). If this does not look like what you expect, quote the entire value to ensure it does not change.

Returning a list of strings prevents that.
2020-07-14 09:38:26 -04:00
John Westcott IV fdb008fb8c Added note about exception if list view return is > max_objects 2020-07-14 09:38:26 -04:00
John Westcott IV d793f0bc99 Making the count check >= instead of just > 2020-07-14 09:38:26 -04:00
John Westcott IV a9c16a6c90 Fixing undefined variabe 2020-07-14 09:38:26 -04:00
John Westcott IV f4454a6c93 Make tower_api a generic GET'er 2020-07-14 09:38:26 -04:00
John Westcott IV 44a3057d16 Initial fixes from github comments 2020-07-14 09:38:26 -04:00
John Westcott IV 3c02265986 Fixing doc issue 2020-07-14 09:38:26 -04:00
John Westcott IV 96ae3268a5 Fixing linting issues 2020-07-14 09:38:26 -04:00
John Westcott IV 6d626b3793 Adding tower_api and tower_get_id lookup plugins 2020-07-14 09:38:26 -04:00
John Westcott IV f091de438e Adding help text 2020-06-24 09:14:30 -04:00
John Westcott IV 8a25f385e4 Modifying tower credential type to include an oauth otken 2020-06-24 09:14:30 -04:00
John Westcott IV 6c6c1e8488 Adding templating of README.md file for Tower vs AWX collections 2020-06-19 09:08:54 -04:00
John Westcott IV 76dcd6d72a Fixing scooby doo fingers 2020-06-08 07:49:58 -04:00
John Westcott IV 64846c3347 Fixing truthy issues 2020-06-08 07:09:45 -04:00
John Westcott IV 95b8bd63ea Fixing linting issues 2020-06-08 07:06:45 -04:00
John Westcott IV 3b60529488 Fixes in testing and parameter processing 2020-06-08 06:42:33 -04:00
John Westcott IV 1f17e02fe9 Adding more documenation and added existing_token_id param 2020-06-05 16:19:23 -04:00
John Westcott IV 0e54f76f80 Fixing missing raw from merge type 2020-06-05 16:10:26 -04:00
John Westcott IV 41d0548af6 Fixing truthy linting issue 2020-06-05 13:53:20 -04:00
John Westcott IV 11da8e254d Changing documention and fixing sanity tests 2020-06-05 13:53:20 -04:00
John Westcott IV 30346618f1 Adding more through testing of tower_oauthtoken including failure messages 2020-06-05 13:53:20 -04:00
John Westcott IV 7c88a51992 Adding more details about tower_oauthtoken parameter 2020-06-05 13:50:39 -04:00
John Westcott IV 1a0407ba50 Fixing ny -> my typos 2020-06-05 13:50:39 -04:00
John Westcott IV 1dbea4614b Rebasing and fixing oauthtoken docs 2020-06-05 13:50:39 -04:00
John Westcott IV 6e9a43513e Removed some debugging and added an exmaple 2020-06-05 13:50:09 -04:00
John Westcott IV e50c8fc9c9 Updated docs and added block on tests 2020-06-05 13:50:09 -04:00
John Westcott IV e6416d770b Initial cut at tower_token module 2020-06-05 13:50:09 -04:00
John Westcott IV 4de7de3ce9 Prevent exception for Non value 2020-06-05 13:29:37 -04:00
John Westcott IV aa54cf097b Now respecting the HAS_YAML variable 2020-06-02 14:54:44 -04:00
John Westcott IV 24571166f6 Fixing fail_json error 2020-06-02 14:40:53 -04:00
John Westcott IV 10a6ad92b7 Fixing tower_schedule oauth_token 2020-05-26 12:31:55 -04:00
John Westcott IV dbeb7ec67c Fixing space issue 2020-05-26 11:23:41 -04:00
John Westcott IV 33aee7f830 Allowing auth_legacy to be converted into tower.tower namespace 2020-05-22 06:32:29 -04:00
John Westcott IV c61e875bf8 Moving tower_oauthtoken into a doc fragement 2020-05-21 13:44:29 -04:00
John Westcott IV d733903a22 Removing ignore_errors from examples 2020-05-21 10:42:13 -04:00
John Westcott IV a2243d91d2 Now actually checking the version instead of just getting it 2020-05-21 09:15:06 -04:00
John Westcott IV 00f8dd9e6a Adding '' option to webhook_service 2020-05-21 08:25:32 -04:00
John Westcott IV a4ec6f6763 Validating the version of python-dateutil 2020-05-20 14:41:43 -04:00
John Westcott IV cc037cb4b5 Removing ignore_errors for tasks which should succeed 2020-05-20 14:41:27 -04:00
John Westcott IV b7ab6ba9bb Attempting to fix py2 test issues 2020-05-15 09:26:34 -04:00
John Westcott IV 31a11cf6bb Attempting to fix py2 test issues 2020-05-15 09:24:44 -04:00
John Westcott IV 81eb9bb78a Now using new X-API headers to test version and type 2020-05-15 09:24:43 -04:00
John Westcott IV 762d8a287e Adding version checking to collection 2020-05-15 09:24:43 -04:00
John Westcott IV 1d91387f58 Adding validation of rrule output thorugh awx searlizer 2020-05-07 14:42:47 -04:00
John Westcott IV 694c7e8af5 Remocing doc fragment extension 2020-05-07 14:42:47 -04:00
John Westcott IV 2ed3a39b46 Changing import 2020-05-07 14:42:47 -04:00
John Westcott IV 0eb7e22d1f Adding requirements on pytz and python.dateutil for rrule lookup plugin 2020-05-07 14:42:47 -04:00
John Westcott IV 12805954e0 Adding rrule lookup plugin 2020-05-07 14:42:46 -04:00
John Westcott IV 0e1a2b899a Initial version of tower_schedule 2020-05-07 14:42:46 -04:00
John Westcott IV 3a6a7c100a Going for a more generic 'just pass' option 2020-04-28 16:47:08 -04:00
John Westcott IV cd07305c08 Set SDB_NOTIFY_HOST on non-docker OS X 2020-04-28 16:37:35 -04:00
John Westcott IV f17ced8f9c Fixing integration tests for deprecation warnings 2020-04-27 14:25:23 -04:00
John Westcott IV 7f66f084f1 Restructuring modules so that lookup don't happen if deleting 2020-04-27 14:11:23 -04:00
John Westcott IV 6b21f2042b Make the module util respect oauth token over username/password 2020-04-14 12:51:45 -04:00
John Westcott IV 6403895eae Puting tasks back to natural order 2020-04-09 12:38:06 -04:00
John Westcott IV a2d1c32da3 Initial commit of tests for tower_workflow_launch 2020-04-09 12:38:06 -04:00
John Westcott IV c1bb62cc36 Removing recursive check, allowwing old pattern to commence 2020-04-06 10:11:18 -04:00
John Westcott IV 6d08e21511 Resolving comment and updating tests 2020-04-06 10:11:18 -04:00
John Westcott IV 8b881d195d Change lookup to include organization 2020-04-06 10:11:18 -04:00
John Westcott IV 5c9ff51248 Change compare_fields to static method 2020-04-06 10:11:18 -04:00
John Westcott IV fd24918ba8 Initial conversion of tower_credential 2020-04-06 10:11:18 -04:00
John Westcott IV 32783f7aaf Fixing linting errors 2020-04-02 09:14:50 -04:00
John Westcott IV 8699a8fbc2 Resolving comments on PR
Made notification type optional

Fixed examples to use notification_configuration

Fixed defaults for headers to prevent deprication warning

Removed default on messages
2020-04-02 09:14:49 -04:00
John Westcott IV b4cde80fa9 Updating example to match test 2020-04-02 09:14:49 -04:00
John Westcott IV eb4db4ed43 Adding field change to readme and example and test of custom messages 2020-04-02 09:14:49 -04:00
John Westcott IV 649aafb454 Initial conversion of tower_notification 2020-04-02 09:14:49 -04:00
John Westcott IV 4b76332daf Added notification of removal of extra_vars_path 2020-03-30 23:35:11 -04:00
John Westcott IV db38339179 Second attempt at converting tower_job_template 2020-03-30 23:35:11 -04:00
John Westcott IV 914ea54925 Make module prefer interval (if set) over min/max
Fix linting issues for True vs true

Fix up unit test related errors
2020-03-27 15:05:23 -04:00
John Westcott IV b9b62e3771 Removing assert that job is pending on job launch 2020-03-27 15:05:23 -04:00
John Westcott IV e03911d378 Depricate min and max interval in favor of interval 2020-03-27 15:05:23 -04:00
John Westcott IV 61287f6b36 Removing old unneeded output and fixing comments 2020-03-27 15:05:23 -04:00
John Westcott IV f6bfdef34d Removed old secho comment from Tower-CLI
Fixed job name for tests
2020-03-27 15:05:23 -04:00
John Westcott IV 7494ba7b9c Initial cut at tower_job_wait conversion 2020-03-27 15:05:23 -04:00
John Westcott IV b99a04dd8d Adding associations to generator 2020-03-26 12:01:48 -04:00
John Westcott IV 357e22eb51 Compensating for default of '' for a JSON typed field 2020-03-26 12:01:48 -04:00
John Westcott IV 8cd4e9b488 Adding state back in 2020-03-20 19:14:00 -04:00
John Westcott IV 1daeec356f Initial converstion of tower_label 2020-03-20 15:01:41 -04:00
John Westcott IV d8513a4e86 Making variables work for hosts
Clear up sanity test and remove redundant import statement
2020-02-26 09:15:04 -05:00
John Westcott IV badd667efa Removing manual and file source types and correcting default for custom_virtualenv 2020-02-26 09:15:04 -05:00
John Westcott IV 7908f25747 Remove reference to default check mode 2020-02-26 09:15:04 -05:00
John Westcott IV 0eef67713f Only try an ID lookup if we can convert the field name_or_id to an integer
Fix linting issues, update tower_project unit test
2020-02-26 09:15:04 -05:00
John Westcott IV 6591efc160 Fixed issue that caused warning message to always display
Because scm_update_cache_timeout has a default and thus will always be != None
2020-02-26 09:15:04 -05:00
John Westcott IV 0685b2fa35 Updates to config file loading
Now supports json or yaml

Depricated multiple k=v on a single line

Remove assert statement and unused import from module_util
2020-02-26 09:15:04 -05:00
John Westcott IV 018dd4c1c3 Fixing config loading issues when the config has no [general] section
Fixed typo in help documentation

Fix up sanity errors and update converted modules

Remove unnecessary test playbook file
2020-02-26 09:15:04 -05:00
John Westcott IV 4fc2c58ae7 Converted tower_job_cancel 2020-02-26 09:15:04 -05:00
John Westcott IV b4014ebabf Converted tower_job_launch.py 2020-02-26 09:15:04 -05:00
John Westcott IV 9955ee6548 Converting tower_inventory_source
Fix up inventory_source module changes, fix import yaml sanity error, change inventory_source unit tests to comply with new structure.
2020-02-26 09:15:04 -05:00
John Westcott IV c08d402e66 Adding mutually exclusive if functionality to support tower_inventory_source 2020-02-26 09:15:04 -05:00
John Westcott IV 1c505beba6 Converted tower_group
Splitting out tower_inventory_source from tower_group

Copy/Paste typo fix and README update for breaking backwards compatability

Update credential_type module and unit tests
2020-02-26 09:15:04 -05:00
John Westcott IV f89061da41 Updating tower_org to use the new tower_api format
Pass sanity and unit tests, update tests

Remove placeholder test function, convert tower_host module, fix misc typos
2020-02-26 09:14:01 -05:00