updated logic
diff --git a/defaults/main.yml b/defaults/main.yml
index cc8aa78..6c8847a 100644
--- a/defaults/main.yml
+++ b/defaults/main.yml
@@ -1,2 +1,10 @@
---
# defaults file for apigee-opdk-setup-bootstrap-rollback
+apigee_packages:
+- apigee*
+- edge*
+- baas*
+- qpid*
+- python-qpid-*
+- libdb-cxx-*
+- nginx-*
diff --git a/tasks/main.yml b/tasks/main.yml
index f96b66c..cadadc9 100644
--- a/tasks/main.yml
+++ b/tasks/main.yml
@@ -10,28 +10,13 @@
shell: "{{ apigee_service }} apigee-service uninstall"
when: apigee_service is defined and apigee_service | trim | length > 0
-#- name: Use no proxy definitions
-# include_tasks: no_proxy.yml
-# when: http_proxy is not defined and https_proxy is not defined
-#
-#- name: Use proxy definitions
-# include_tasks: with_proxy.yml
-# when: http_proxy is defined and https_proxy is defined
-
- name: Remove apigee, edge, baas and qpid packages
become: yes
ignore_errors: yes
yum:
name: '{{ item }}'
state: absent
- with_items:
- - apigee*
- - edge*
- - baas*
- - qpid*
- - python-qpid-*
- - libdb-cxx-*
- - nginx-*
+ with_items: "{{ apigee_packages}}"
environment:
http_proxy: "{{ http_proxy }}"
https_proxy: "{{ https_proxy }}"
diff --git a/tasks/no_proxy.yml b/tasks/no_proxy.yml
deleted file mode 100644
index 250f920..0000000
--- a/tasks/no_proxy.yml
+++ /dev/null
@@ -1,15 +0,0 @@
----
-- name: Remove apigee, edge, baas and qpid packages
- become: yes
- ignore_errors: yes
- yum:
- name: '{{ item }}'
- state: absent
- with_items:
- - apigee*
- - edge*
- - baas*
- - qpid*
- - python-qpid-*
- - libdb-cxx-*
- - nginx-*
diff --git a/tasks/with_proxy.yml b/tasks/with_proxy.yml
deleted file mode 100644
index 858ff67..0000000
--- a/tasks/with_proxy.yml
+++ /dev/null
@@ -1,18 +0,0 @@
----
-- name: Remove apigee, edge, baas and qpid packages
- become: yes
- ignore_errors: yes
- yum:
- name: '{{ item }}'
- state: absent
- with_items:
- - apigee*
- - edge*
- - baas*
- - qpid*
- - python-qpid-*
- - libdb-cxx-*
- - nginx-*
- environment:
- http_proxy: "{{ http_proxy }}"
- https_proxy: "{{ https_proxy }}"