mirror of
https://github.com/ansible/awx.git
synced 2026-05-08 01:47:35 -02:30
Update README with recent Collections changes
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
This Ansible collection allows for easy interaction with an AWX server via Ansible playbooks.
|
This Ansible collection allows for easy interaction with an AWX server via Ansible playbooks.
|
||||||
|
|
||||||
This source for this collection lives in the `awx_collection` folder inside of the
|
This source for this collection lives in the `awx_collection` folder inside of the
|
||||||
AWX source.
|
AWX GitHub repository.
|
||||||
The previous home for this collection was inside the folder [lib/ansible/modules/web_infrastructure/ansible_tower](https://github.com/ansible/ansible/tree/stable-2.9/lib/ansible/modules/web_infrastructure/ansible_tower) in the Ansible repo,
|
The previous home for this collection was inside the folder [lib/ansible/modules/web_infrastructure/ansible_tower](https://github.com/ansible/ansible/tree/stable-2.9/lib/ansible/modules/web_infrastructure/ansible_tower) in the Ansible repo,
|
||||||
as well as other places for the inventory plugin, module utils, and
|
as well as other places for the inventory plugin, module utils, and
|
||||||
doc fragment.
|
doc fragment.
|
||||||
@@ -72,7 +72,11 @@ Notable releases of the `awx.awx` collection:
|
|||||||
|
|
||||||
The following notes are changes that may require changes to playbooks:
|
The following notes are changes that may require changes to playbooks:
|
||||||
|
|
||||||
- The module tower_notification was renamed tower_notification_template. In ansible >= 2.10 there is a seamless redirect. Ansible 2.9 does not respect the redirect.
|
- The `credential` module no longer allows `kind` as a parameter; additionally, `inputs` must now be used with a variety of key/value parameters to go with it (e.g., `become_method`)
|
||||||
|
- The `job_wait` module no longer allows `min_interval`/ `max_interval` parameters; use `interval` instead
|
||||||
|
- The `notification_template` requires various notification configuration information to be listed as a dictionary under the `notification_configuration` parameter (e.g., `use_ssl`)
|
||||||
|
- In the `inventory_source` module, the `source_project` (when provided) lookup defaults to the specified organization in the same way the inventory is looked up
|
||||||
|
- The module `tower_notification` was renamed `tower_notification_template`. In `ansible >= 2.10` there is a seamless redirect. Ansible 2.9 does not respect the redirect.
|
||||||
- When a project is created, it will wait for the update/sync to finish by default; this can be turned off with the `wait` parameter, if desired.
|
- When a project is created, it will wait for the update/sync to finish by default; this can be turned off with the `wait` parameter, if desired.
|
||||||
- Creating a "scan" type job template is no longer supported.
|
- Creating a "scan" type job template is no longer supported.
|
||||||
- Specifying a custom certificate via the `TOWER_CERTIFICATE` environment variable no longer works.
|
- Specifying a custom certificate via the `TOWER_CERTIFICATE` environment variable no longer works.
|
||||||
@@ -94,16 +98,16 @@ The following notes are changes that may require changes to playbooks:
|
|||||||
- Some return values (e.g., `credential_type`) have been removed. Use of `id` is recommended.
|
- Some return values (e.g., `credential_type`) have been removed. Use of `id` is recommended.
|
||||||
- `tower_job_template` no longer supports the deprecated `extra_vars_path` parameter, please use `extra_vars` with the lookup plugin to replace this functionality.
|
- `tower_job_template` no longer supports the deprecated `extra_vars_path` parameter, please use `extra_vars` with the lookup plugin to replace this functionality.
|
||||||
- The `notification_configuration` parameter of `tower_notification_template` has changed from a string to a dict. Please use the `lookup` plugin to read an existing file into a dict.
|
- The `notification_configuration` parameter of `tower_notification_template` has changed from a string to a dict. Please use the `lookup` plugin to read an existing file into a dict.
|
||||||
- `tower_credential` no longer supports passing a file name to ssh_key_data.
|
- `tower_credential` no longer supports passing a file name to `ssh_key_data`.
|
||||||
- The HipChat `notification_type` has been removed and can no longer be created using the `tower_notification_template` module.
|
- The HipChat `notification_type` has been removed and can no longer be created using the `tower_notification_template` module.
|
||||||
|
|
||||||
## Running Unit Tests
|
## Running Unit Tests
|
||||||
|
|
||||||
Tests to verify compatibility with the most recent AWX code are in `awx_collection/test/awx`.
|
Tests to verify compatibility with the most recent AWX code are in `awx_collection/test/awx`.
|
||||||
These can be ran by `make test_collection` in the development container.
|
These can be ran via the `make test_collection` command in the development container.
|
||||||
|
|
||||||
To run outside of the development container, or to run against
|
To run tests outside of the development container, or to run against
|
||||||
Ansible source, set up a working environment:
|
Ansible source, set up a dedicated virtual environment:
|
||||||
|
|
||||||
```
|
```
|
||||||
mkvirtualenv my_new_venv
|
mkvirtualenv my_new_venv
|
||||||
@@ -118,11 +122,11 @@ py.test awx_collection/test/awx/
|
|||||||
|
|
||||||
## Running Integration Tests
|
## Running Integration Tests
|
||||||
|
|
||||||
The integration tests require a virtualenv with `ansible` >= 2.9 and `awxkit`.
|
The integration tests require a virtualenv with `ansible >= 2.9` and `awxkit`.
|
||||||
The collection must first be installed, which can be done using `make install_collection`.
|
The collection must first be installed, which can be done using `make install_collection`.
|
||||||
You also need a configuration file, as described in the running section.
|
You also need a configuration file, as described in the [Running](https://github.com/ansible/awx/blob/devel/awx_collection/README.md#running) section.
|
||||||
|
|
||||||
Run the tests:
|
How to run the tests:
|
||||||
|
|
||||||
```
|
```
|
||||||
# ansible-test must be run from the directory in which the collection is installed
|
# ansible-test must be run from the directory in which the collection is installed
|
||||||
@@ -133,5 +137,5 @@ ansible-test integration
|
|||||||
## Licensing
|
## Licensing
|
||||||
|
|
||||||
All content in this folder is licensed under the same license as Ansible,
|
All content in this folder is licensed under the same license as Ansible,
|
||||||
which is the same as license that applied before the split into an
|
which is the same as the license that applied before the split into an
|
||||||
independent collection.
|
independent collection.
|
||||||
|
|||||||
@@ -61,7 +61,7 @@
|
|||||||
- block:
|
- block:
|
||||||
- name: "Wait for up to a minute until the job enters the can_cancel: False state"
|
- name: "Wait for up to a minute until the job enters the can_cancel: False state"
|
||||||
debug:
|
debug:
|
||||||
msg: "The job can_cancel status has transitioned into False, we can proveed with testing"
|
msg: "The job can_cancel status has transitioned into False, we can proceed with testing"
|
||||||
until: not job_status
|
until: not job_status
|
||||||
retries: 6
|
retries: 6
|
||||||
delay: 10
|
delay: 10
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
This Ansible collection allows for easy interaction with an {% if collection_package | lower() == 'awx' %}AWX{% else %}Red Hat Ansible Automation Platform{% endif %} server via Ansible playbooks.
|
This Ansible collection allows for easy interaction with an {% if collection_package | lower() == 'awx' %}AWX{% else %}Red Hat Ansible Automation Platform{% endif %} server via Ansible playbooks.
|
||||||
|
|
||||||
This source for this collection lives in the `awx_collection` folder inside of the
|
This source for this collection lives in the `awx_collection` folder inside of the
|
||||||
AWX source.
|
AWX GitHub repository.
|
||||||
The previous home for this collection was inside the folder [lib/ansible/modules/web_infrastructure/ansible_tower](https://github.com/ansible/ansible/tree/stable-2.9/lib/ansible/modules/web_infrastructure/ansible_tower) in the Ansible repo,
|
The previous home for this collection was inside the folder [lib/ansible/modules/web_infrastructure/ansible_tower](https://github.com/ansible/ansible/tree/stable-2.9/lib/ansible/modules/web_infrastructure/ansible_tower) in the Ansible repo,
|
||||||
as well as other places for the inventory plugin, module utils, and
|
as well as other places for the inventory plugin, module utils, and
|
||||||
doc fragment.
|
doc fragment.
|
||||||
@@ -83,7 +83,11 @@ Notable releases of the `{{ collection_namespace }}.{{ collection_package }}` co
|
|||||||
|
|
||||||
The following notes are changes that may require changes to playbooks:
|
The following notes are changes that may require changes to playbooks:
|
||||||
|
|
||||||
- The module tower_notification was renamed tower_notification_template. In ansible >= 2.10 there is a seamless redirect. Ansible 2.9 does not respect the redirect.
|
- The `credential` module no longer allows `kind` as a parameter; additionally, `inputs` must now be used with a variety of key/value parameters to go with it (e.g., `become_method`)
|
||||||
|
- The `job_wait` module no longer allows `min_interval`/ `max_interval` parameters; use `interval` instead
|
||||||
|
- The `notification_template` requires various notification configuration information to be listed as a dictionary under the `notification_configuration` parameter (e.g., `use_ssl`)
|
||||||
|
- In the `inventory_source` module, the `source_project` (when provided) lookup defaults to the specified organization in the same way the inventory is looked up
|
||||||
|
- The module `tower_notification` was renamed `tower_notification_template`. In `ansible >= 2.10` there is a seamless redirect. Ansible 2.9 does not respect the redirect.
|
||||||
- When a project is created, it will wait for the update/sync to finish by default; this can be turned off with the `wait` parameter, if desired.
|
- When a project is created, it will wait for the update/sync to finish by default; this can be turned off with the `wait` parameter, if desired.
|
||||||
- Creating a "scan" type job template is no longer supported.
|
- Creating a "scan" type job template is no longer supported.
|
||||||
- Specifying a custom certificate via the `TOWER_CERTIFICATE` environment variable no longer works.
|
- Specifying a custom certificate via the `TOWER_CERTIFICATE` environment variable no longer works.
|
||||||
@@ -105,17 +109,17 @@ The following notes are changes that may require changes to playbooks:
|
|||||||
- Some return values (e.g., `credential_type`) have been removed. Use of `id` is recommended.
|
- Some return values (e.g., `credential_type`) have been removed. Use of `id` is recommended.
|
||||||
- `tower_job_template` no longer supports the deprecated `extra_vars_path` parameter, please use `extra_vars` with the lookup plugin to replace this functionality.
|
- `tower_job_template` no longer supports the deprecated `extra_vars_path` parameter, please use `extra_vars` with the lookup plugin to replace this functionality.
|
||||||
- The `notification_configuration` parameter of `tower_notification_template` has changed from a string to a dict. Please use the `lookup` plugin to read an existing file into a dict.
|
- The `notification_configuration` parameter of `tower_notification_template` has changed from a string to a dict. Please use the `lookup` plugin to read an existing file into a dict.
|
||||||
- `tower_credential` no longer supports passing a file name to ssh_key_data.
|
- `tower_credential` no longer supports passing a file name to `ssh_key_data`.
|
||||||
- The HipChat `notification_type` has been removed and can no longer be created using the `tower_notification_template` module.
|
- The HipChat `notification_type` has been removed and can no longer be created using the `tower_notification_template` module.
|
||||||
|
|
||||||
{% if collection_package | lower() == "awx" %}
|
{% if collection_package | lower() == "awx" %}
|
||||||
## Running Unit Tests
|
## Running Unit Tests
|
||||||
|
|
||||||
Tests to verify compatibility with the most recent AWX code are in `awx_collection/test/awx`.
|
Tests to verify compatibility with the most recent AWX code are in `awx_collection/test/awx`.
|
||||||
These can be ran by `make test_collection` in the development container.
|
These can be ran via the `make test_collection` command in the development container.
|
||||||
|
|
||||||
To run outside of the development container, or to run against
|
To run tests outside of the development container, or to run against
|
||||||
Ansible source, set up a working environment:
|
Ansible source, set up a dedicated virtual environment:
|
||||||
|
|
||||||
```
|
```
|
||||||
mkvirtualenv my_new_venv
|
mkvirtualenv my_new_venv
|
||||||
@@ -130,11 +134,11 @@ py.test awx_collection/test/awx/
|
|||||||
|
|
||||||
## Running Integration Tests
|
## Running Integration Tests
|
||||||
|
|
||||||
The integration tests require a virtualenv with `ansible` >= 2.9 and `awxkit`.
|
The integration tests require a virtualenv with `ansible >= 2.9` and `awxkit`.
|
||||||
The collection must first be installed, which can be done using `make install_collection`.
|
The collection must first be installed, which can be done using `make install_collection`.
|
||||||
You also need a configuration file, as described in the running section.
|
You also need a configuration file, as described in the [Running](https://github.com/ansible/awx/blob/devel/awx_collection/README.md#running) section.
|
||||||
|
|
||||||
Run the tests:
|
How to run the tests:
|
||||||
|
|
||||||
```
|
```
|
||||||
# ansible-test must be run from the directory in which the collection is installed
|
# ansible-test must be run from the directory in which the collection is installed
|
||||||
@@ -146,5 +150,5 @@ ansible-test integration
|
|||||||
## Licensing
|
## Licensing
|
||||||
|
|
||||||
All content in this folder is licensed under the same license as Ansible,
|
All content in this folder is licensed under the same license as Ansible,
|
||||||
which is the same as license that applied before the split into an
|
which is the same as the license that applied before the split into an
|
||||||
independent collection.
|
independent collection.
|
||||||
|
|||||||
Reference in New Issue
Block a user