Repository for OpenStack Helm infrastructure-related code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.9KB

  1. # Copyright 2017 The Openstack-Helm Authors.
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. - name: ensuring SELinux is disabled on centos & fedora
  15. when: ansible_distribution == 'CentOS' or ansible_distribution == 'Red Hat Enterprise Linux' or ansible_distribution == 'Fedora'
  16. become: true
  17. become_user: root
  18. command: setenforce 0
  19. ignore_errors: True
  20. #NOTE(portdirect): See https://ask.openstack.org/en/question/110437/importerror-cannot-import-name-unrewindablebodyerror/
  21. - name: fix docker removal issue with ansible's docker_container on centos
  22. when: ansible_distribution == 'CentOS' or ansible_distribution == 'Red Hat Enterprise Linux'
  23. block:
  24. - name: remove requests and urllib3 distro packages to fix docker removal issue with ansible's docker_container on centos
  25. include_role:
  26. name: deploy-package
  27. tasks_from: dist
  28. vars:
  29. state: absent
  30. packages:
  31. rpm:
  32. - python-urllib3
  33. - python-requests
  34. - name: restore requests and urllib3 distro packages to fix docker removal issue with ansible's docker_container on centos
  35. include_role:
  36. name: deploy-package
  37. tasks_from: dist
  38. vars:
  39. state: present
  40. packages:
  41. rpm:
  42. - python-urllib3
  43. - python-requests
  44. - name: Ensure docker python packages deployed
  45. include_role:
  46. name: deploy-package
  47. tasks_from: pip
  48. vars:
  49. packages:
  50. - docker