summaryrefslogtreecommitdiffstats
path: root/roles/openshift_cli
diff options
context:
space:
mode:
authorJason DeTiberus <jdetiber@redhat.com>2016-02-26 11:12:16 -0500
committerJason DeTiberus <jdetiber@redhat.com>2016-03-14 11:38:13 -0400
commit1565bc6e71bdda712d4cfdbf28754f00b38a4674 (patch)
tree8e5774e28e5ea233f09ffdcc446b6f692ab0cf2f /roles/openshift_cli
parenta0e7f19f9f7f423d8fe001a247ccf2c98d815d68 (diff)
downloadopenshift-1565bc6e71bdda712d4cfdbf28754f00b38a4674.tar.gz
openshift-1565bc6e71bdda712d4cfdbf28754f00b38a4674.tar.bz2
openshift-1565bc6e71bdda712d4cfdbf28754f00b38a4674.tar.xz
openshift-1565bc6e71bdda712d4cfdbf28754f00b38a4674.zip
Docker role refactor
- refactors the docker role to push generic config into docker role and wrap openshift specific variables into an openshift_docker role and it's dependent openshift_docker_facts role - adds support for setting --confirm-def-push flag (Resolves https://github.com/openshift/openshift-ansible/issues/1014) - moves docker related facts from common/node roles to a new docker role - renames cli_docker_* role varialbes to openshift_docker-* (maintaining backward compatibility) - update role dependencies to pull in openshift_docker conditionally based on is_containerized - remove playbooks/common/openshift-docker since the docker role is now conditionally included
Diffstat (limited to 'roles/openshift_cli')
-rw-r--r--roles/openshift_cli/meta/main.yml5
-rw-r--r--roles/openshift_cli/tasks/main.yml8
2 files changed, 7 insertions, 6 deletions
diff --git a/roles/openshift_cli/meta/main.yml b/roles/openshift_cli/meta/main.yml
index 1e8f8b719..4351e8f24 100644
--- a/roles/openshift_cli/meta/main.yml
+++ b/roles/openshift_cli/meta/main.yml
@@ -12,5 +12,6 @@ galaxy_info:
categories:
- cloud
dependencies:
-- { role: openshift_common }
-- { role: docker }
+- role: openshift_docker
+ when: openshift.common.is_containerized | bool
+- role: openshift_common
diff --git a/roles/openshift_cli/tasks/main.yml b/roles/openshift_cli/tasks/main.yml
index 3b224416e..62a4dd690 100644
--- a/roles/openshift_cli/tasks/main.yml
+++ b/roles/openshift_cli/tasks/main.yml
@@ -4,7 +4,7 @@
local_facts:
deployment_type: "{{ openshift_deployment_type }}"
cli_image: "{{ osm_image | default(None) }}"
-
+
- name: Install clients
action: "{{ ansible_pkg_mgr }} name={{ openshift.common.service_type }}-clients state=present"
when: not openshift.common.is_containerized | bool
@@ -13,16 +13,16 @@
command: >
docker pull {{ openshift.common.cli_image }}:{{ openshift_version }}
when: openshift.common.is_containerized | bool
-
+
- name: Create /usr/local/bin/openshift cli wrapper
template:
src: openshift.j2
dest: /usr/local/bin/openshift
mode: 0755
when: openshift.common.is_containerized | bool
-
+
- name: Create client symlinks
- file:
+ file:
path: "{{ item }}"
state: link
src: /usr/local/bin/openshift