1
0
mirror of https://github.com/ansible/awx.git synced 2024-10-30 05:25:29 +03:00
Commit Graph

178 Commits

Author SHA1 Message Date
John Westcott IV
68926dad27 Adding team_fields
Convert job_list and inventory modules, other changes to make sanity tests pass
2020-02-26 09:14:00 -05:00
John Westcott IV
ceb6f6c47d Converted tower_settings
Changed comments
2020-02-26 09:14:00 -05:00
John Westcott IV
167e99fce9 Converted tower_user 2020-02-26 09:14:00 -05:00
John Westcott IV
c930011616 Removing default_check_mode 2020-02-26 09:14:00 -05:00
John Westcott IV
aaaca63f83 Converted tower_organization 2020-02-26 09:14:00 -05:00
John Westcott IV
d8a9f663b1 Converted tower_credential_type.py 2020-02-26 09:14:00 -05:00
John Westcott IV
b0d0ccf44f Fix fail_json and remove redundant handle check mode 2020-02-26 09:14:00 -05:00
John Westcott IV
c57754a29b Logout is now handled by exit_json 2020-02-26 09:14:00 -05:00
John Westcott IV
65057c1fb7 Auto-handle check_mode on post, patch, delete and update_if_needed methods 2020-02-26 09:14:00 -05:00
John Westcott IV
d8be6490c2 Only warn if we can't release a tower token 2020-02-26 09:14:00 -05:00
John Westcott IV
b34208d1b6 Attempting to fix logout loop 2020-02-26 09:14:00 -05:00
John Westcott IV
0d5a9e9c8c Initial implementation of Pull #5337 2020-02-26 09:14:00 -05:00
Bill Nottingham
341c6ae767 Also remove some dangling rax from awxkit and collection modules. 2020-02-25 15:18:26 -05:00
AlanCoding
d62994ec02
Update metadata for the AWX collection 2020-02-20 22:36:55 -05:00
Caleb Boylan
79e65e3e84 Open collection config 'r' for py3 compatibility 2020-01-29 08:17:07 -08:00
Elijah DeLee
1e796076f5 Scan jobs have been removed, clean up old refs
see https://github.com/ansible/awx/issues/5603
2020-01-21 12:11:53 -05:00
beeankha
ef36b4fffd Reduce number of requests running in the try/except block 2020-01-17 15:08:05 -05:00
beeankha
792f68eaec When Job Template is not found, fail more gracefully 2020-01-17 11:40:41 -05:00
softwarefactory-project-zuul[bot]
525fd889e9
Merge pull request #5584 from AlanCoding/vault_credential_test
[AWX collection] Add test for deprecated vault_credential

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2020-01-16 14:53:35 +00:00
beeankha
fa043100bd Add info to changelog 2020-01-16 08:35:56 -05:00
beeankha
db0d748302 Also check for survey_enabled parameter 2020-01-16 08:35:56 -05:00
beeankha
e8a95a1dac Fail the task if extra_vars is set on launch but ask_extra_vars is not set to True on the Job Template 2020-01-16 08:35:56 -05:00
AlanCoding
b9b6dad0b3
Add test for deprecated vault_credential 2020-01-15 09:44:28 -05:00
beeankha
b19e5aab28 Raise AnsibleParserError via a custom exception 2020-01-09 15:30:23 -05:00
beeankha
0c696bfd96 Add new CollectionsParserError class for exceptions 2020-01-09 09:14:47 -05:00
beeankha
63ffff3b76 Import request into module_utils instead 2020-01-09 09:14:47 -05:00
beeankha
c532c6fe61 Update parameters, add whitespace 2020-01-09 09:14:47 -05:00
beeankha
61c2968a7c Fix module-specific lint errors 2020-01-09 09:14:47 -05:00
beeankha
d9e41547a1 Refactor Inventory Plugin module to import from module_utils 2020-01-09 09:14:47 -05:00
beeankha
f37ac1dcc9 Add extra_vars example to Job Launch module, update extra_vars type to dict,
update unit test, add details to Collections release notes.
2020-01-08 14:50:41 -05:00
Jake Jackson
caad204cbb Merge branch 'devel' of github.com:ansible/awx into fix_collection_sanity 2019-12-18 09:52:24 -05:00
Jake Jackson
15041e57b2 sqaushed and fixed sanity test issues 2019-12-09 12:22:46 -05:00
beeankha
3cc9139c6d Add a more specific assertion statement 2019-12-05 16:49:23 -05:00
beeankha
6d595cbda6 Add extra_vars parameter to tower_job_template module 2019-12-05 15:37:00 -05:00
Yanis Guenane
ca247182df yamllint: Make all files in awx pass yamllint
This commit updates all files that weren't passing yamllint for them to
pass.

A new yamllint target has been added. One can run `tox -e yamllint` or
`yamllint -s .` locally to ensure yaml files are still passing.

This check will be enabled in the CI so it can get on every new
contributions, and prevent merging non-compliant code.

Signed-off-by: Yanis Guenane <yguenane@redhat.com>
2019-12-02 15:12:51 +01:00
AlanCoding
081a0fc04e
fix other assorted sanity failures 2019-11-26 09:45:54 -05:00
AlanCoding
48f10669d6
fix duplicate exception sanity error 2019-11-26 09:39:05 -05:00
beeankha
3ed5d6ec65 Make integrations pass even with manual SCM type 2019-11-25 15:16:41 -05:00
David Moreau Simard
2171823846
Finish JT.credentials functionality, add test
Original commit:

commit 3ec6196477135230c4b90b175310bdc2eaff36ed
Author: David Moreau Simard <dmsimard@redhat.com>
Date:   Tue Oct 23 22:21:33 2018 -0400

    Add support for "credentials" in the tower_job_template module

    Job templates might require more than one credential.
    There's credential, vault_credential, machine_credential, etc.
    "credentials" is a thing, let's support it.
2019-11-21 14:30:08 -05:00
softwarefactory-project-zuul[bot]
57f9b31b2b
Merge pull request #5163 from AlanCoding/custom_venv
Add custom virtualenv param to various modules

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-21 11:45:19 +00:00
softwarefactory-project-zuul[bot]
34ba858e3b
Merge pull request #5191 from AlanCoding/tower_group_id
Make tower_group idempotent

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-21 04:26:16 +00:00
AlanCoding
5e24cee0ae
Add custom_virtualenv param to inventory source and tests 2019-11-20 22:39:12 -05:00
Mathieu Mallet
a026838f77
ansible_tower: Add custom_virtualenv attribute when applicable (#60200)
In Ansible Tower/AWX, there are three kinds of objects that can be tied
to custom python virtual environment:
  - job template
  - project
  - organization

This patch updates the three ansible modules that creates those objects
so that the 'custom_virtualenv' attribute can be set if specified.

Testing Done: via a playbook, test organization, projet then template creation
without any 'custom_virtualenv' attribute specified. Check that the
resources get created and that their python env is set to default. Then
re-do the same test but this time with the 'custom_virtualenv' attribute
specified. Ensure in AWX UI that those resources have the right
'custom_virtualenv' set.
2019-11-20 22:35:25 -05:00
softwarefactory-project-zuul[bot]
fed6a86170
Merge pull request #5194 from AlanCoding/inventory_organization
Add organization parameter to tower_inventory_source (and add test logging)

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-20 18:23:27 +00:00
beeankha
c6d2fa86c7 Fix typo under 'options' 2019-11-20 11:15:18 -05:00
beeankha
eff46dbc71 Make playbook wait for project sync...
...*before* running the associated job template.

Set "wait" default to True so CI doesn't time out

Change default back to "False", put in new "if"...

...block, explicitly set "wait" to "False" in test file.

Change if block

Update README

Update 'wait' option description
2019-11-20 08:43:19 -05:00
softwarefactory-project-zuul[bot]
e8606d9478
Merge pull request #5301 from AlanCoding/galaxy_ignore
Add ignore list for Ansible 2.10

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-16 01:22:53 +00:00
softwarefactory-project-zuul[bot]
9701ac1804
Merge pull request #5329 from AlanCoding/rm_another_ignore
Run and fix all sanity tests

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-14 21:25:44 +00:00
softwarefactory-project-zuul[bot]
3d90c6dfcf
Merge pull request #5319 from AlanCoding/just_one_letter
Update documentation example

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-14 19:48:26 +00:00
AlanCoding
1402a2c8a5
Run and fix all sanity tests 2019-11-14 14:45:16 -05:00
softwarefactory-project-zuul[bot]
6567ad612c
Merge pull request #5170 from AlanCoding/py2_fix2
Fix multibyte character handling issue for tower_job_wait #55585

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-11-14 19:33:50 +00:00
James Vornhagen
9a9d53d17a
update documentation example
missing k in workflow.

- Docs Pull Request

+label: docsite_pr
2019-11-13 22:00:18 -05:00
AlanCoding
c96e88877f
Add ignore list for Ansible 2.10 2019-11-11 22:07:22 -05:00
softwarefactory-project-zuul[bot]
43bf370f8c
Merge pull request #5195 from AlanCoding/job_fail_json
In tower_job_wait intentionally fail module for failure

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-10-31 17:53:53 +00:00
softwarefactory-project-zuul[bot]
6982a8aee7
Merge pull request #5176 from AlanCoding/collection_project_create
Fix and test for warning when creating project

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
2019-10-31 16:50:59 +00:00
AlanCoding
5095816762
In tower_job_wait intentionally fail module for failure 2019-10-31 12:41:53 -04:00
AlanCoding
24eae09ed9
Make tower_inventory_source org optional, add tests 2019-10-31 09:46:49 -04:00
Hampus Lundqvist
a2fee252f9
fix tests and typos 2019-10-31 08:09:37 -04:00
Hampus Lundqvist
ab80c2276d
support organization specific tower_inventory_source. Inventories can exists with same name across multiple organizations so we need to be able to select correct inventory, credential, project etc for the inventory_source 2019-10-31 08:09:20 -04:00
AlanCoding
da1e43dc12
Make tower_group idempotent 2019-10-31 07:53:43 -04:00
AlanCoding
db33c0e4fa
Add test coverage for launch with multiple prompted creds 2019-10-30 20:41:14 -04:00
AlanCoding
f8b64f2222
Fix and test for warning when creating project 2019-10-30 15:40:49 -04:00
Hideki Saito
cb354c2ef1
Fix multibyte character handling issue for tower_job_wait #55585
Add multibyte hostname handling test as an integration test

Signed-off-by: Hideki Saito <saito@fgrep.org>
2019-10-30 14:11:49 -04:00
AlanCoding
0160dbe8bc
Remove sanity exceptions no longer needed 2019-10-30 12:56:36 -04:00
AlanCoding
59e1c6d492
Add collection test coverage for creating vault credential 2019-10-29 15:34:32 -04:00
Mathieu Mallet
ae1bd9d1e9
tower_credential: Missing 'kind' attribute (#61324)
In the 'tower_credential' module, when the credential 'kind' is set to
'vault', the code expects the other parameter 'vault_id' to be set.
Unfortunately, in the module 'credential_type_for_v1_kind' method, the
'kind' parameter is popped, i.e. remove from the module dict of
parameters leading to the following error:

> Parameter 'vault_id' is only valid if parameter 'kind' is specified as
'vault'

Fixes: #45644, #61324

Testing Done: Manually create a playbook with a task as follow
  - name: Create vault with ID 'bar' exists
    tower_credential:
      name: Foobar vault
      organization: Foobar
      kind: vault
      vault_id: bar
      vault_password: foobar
2019-10-29 14:21:21 -04:00
Alan Rominger
98d3f3dc8a
Add tests for AWX collection credential fixes (#3893) 2019-10-29 11:24:16 -04:00
AlanCoding
1bdae2d1f7
Fully rely on error ignoring for sanity rel imports 2019-10-29 11:24:16 -04:00
AlanCoding
2bc2e26cc7
Ignore import errors due to bugs in Ansible core 2019-10-29 11:24:16 -04:00
AlanCoding
5010602e6b
add release note 2019-10-29 11:24:16 -04:00
AlanCoding
c103a813bf
declare types in Ansible Tower module options 2019-10-29 11:24:16 -04:00
AlanCoding
e097bc61c8
New target for sanity testing of the collection
Do not run in Zuul
2019-10-29 11:24:15 -04:00
Alan Rominger
70269d9a0d
Add support for credential_type in tower_credential module (#3820)
* Add support for credential_type

* Finish up credential_type parameter with tests

* make inputs mutually exclusive with other params

* Test credential type with dict input
2019-10-29 11:24:12 -04:00
AlanCoding
16ebfe3a63
use fully qualified inventory plugin name 2019-10-10 08:51:18 -04:00
AlanCoding
db0bd471c3
rename playbook vars to have collection_ 2019-10-01 13:45:07 -04:00
AlanCoding
7dd8e35e8c
Use namespaced doc fragment, cleanup
doc fragment will now be at awx.awx.auth
changed from just tower, which source from core

remove Makefile things no longer needed
2019-09-27 23:09:39 -04:00
AlanCoding
75bb7aae14
update references to collection folder 2019-09-27 14:29:04 -04:00
AlanCoding
98619c5e23
rename awx modules folder to collection 2019-09-27 14:29:04 -04:00