Bug 1583817 - openshift-ansible aws provisioning - ec2_ami_find module is deprecated
Summary: openshift-ansible aws provisioning - ec2_ami_find module is deprecated
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 3.9.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 3.11.0
Assignee: Chris Callegari
QA Contact: sheng.lao
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-29 18:56 UTC by Chris Callegari
Modified: 2018-10-11 07:20 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: AMI discovery tasks relied on a deprecated Ansible module. Consequence: Running openshift-ansible AWS provision plays would display a deprecation warning. Fix: Tasks have been migrated to modern ec2_ami_facts module. Result: Warning is no longer displayed.
Clone Of:
Environment:
Last Closed: 2018-10-11 07:20:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:2652 0 None None None 2018-10-11 07:20:30 UTC

Description Chris Callegari 2018-05-29 18:56:42 UTC
Description of problem:

When creating an ami in openshift-ansible provisioning, Ansible displays the following warning...
[DEPRECATION WARNING]: ec2_ami_find is kept for backwards compatibility but usage is discouraged. The module documentation details page may
 explain more about this rationale.. This feature will be removed in a future release. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.

Code can be found here (there are other instances in the same data structure):

Version-Release number of the following components:

openshift-ansible 3.9, 3.10


How reproducible: Always

Steps to Reproduce:
1. ansible-playbook -i inventory.yml openshift-cluster/build_ami.yml -e @provisioning_vars.yml


Expected results:
1. ansible-playbook -i inventory.yml openshift-cluster/build_ami.yml -e @provisioning_vars.yml

PLAY [localhost] ***

TASK ...

TASK ...


Warning is not shown

Comment 1 Chris Callegari 2018-08-22 19:02:11 UTC
See https://github.com/openshift/openshift-ansible/pull/9722

Comment 2 Chris Callegari 2018-08-23 14:44:32 UTC
pull/97222 is merged.

Please test from master.  build_ami, provision, and provision_nodes plays should not display warning "[DEPRECATION WARNING]: ec2_ami_find..."

Comment 3 sheng.lao 2018-08-31 05:53:28 UTC
Fixed at: openshift-ansible-3.11.0-0.25.0-34-g04f8519

# grep ec2_ami_find *logs*   
# 
# grep ec2_ami_facts *logs*
Using module file /usr/lib/python2.7/site-packages/ansible/modules/cloud/amazon/ec2_ami_facts.py
:Using module file /usr/lib/python2.7/site-packages/ansible/modules/cloud/amazon/ec2_ami_facts.py

Comment 6 errata-xmlrpc 2018-10-11 07:20:02 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:2652


Note You need to log in before you can comment on or make changes to this bug.