summaryrefslogtreecommitdiffstats
path: root/ci/ansible/roles/nbp-installer/scenarios
diff options
context:
space:
mode:
Diffstat (limited to 'ci/ansible/roles/nbp-installer/scenarios')
-rw-r--r--ci/ansible/roles/nbp-installer/scenarios/csi.yml4
-rw-r--r--ci/ansible/roles/nbp-installer/scenarios/flexvolume.yml33
-rw-r--r--ci/ansible/roles/nbp-installer/scenarios/release.yml8
-rw-r--r--ci/ansible/roles/nbp-installer/scenarios/repository.yml2
4 files changed, 40 insertions, 7 deletions
diff --git a/ci/ansible/roles/nbp-installer/scenarios/csi.yml b/ci/ansible/roles/nbp-installer/scenarios/csi.yml
index 93fff88..ef86967 100644
--- a/ci/ansible/roles/nbp-installer/scenarios/csi.yml
+++ b/ci/ansible/roles/nbp-installer/scenarios/csi.yml
@@ -19,14 +19,14 @@
regexp: '^ opensdsendpoint'
line: ' opensdsendpoint: {{ opensds_endpoint }}'
backup: yes
-
+
- name: Configure opensds auth strategy in opensds csi plugin
lineinfile:
dest: "{{ nbp_work_dir }}/csi/deploy/kubernetes/csi-configmap-opensdsplugin.yaml"
regexp: '^ opensdsauthstrategy'
line: ' opensdsauthstrategy: {{ opensds_auth_strategy }}'
backup: yes
-
+
- name: Configure keystone os auth url in opensds csi plugin
lineinfile:
dest: "{{ nbp_work_dir }}/csi/deploy/kubernetes/csi-configmap-opensdsplugin.yaml"
diff --git a/ci/ansible/roles/nbp-installer/scenarios/flexvolume.yml b/ci/ansible/roles/nbp-installer/scenarios/flexvolume.yml
index 52ec16d..2117411 100644
--- a/ci/ansible/roles/nbp-installer/scenarios/flexvolume.yml
+++ b/ci/ansible/roles/nbp-installer/scenarios/flexvolume.yml
@@ -21,5 +21,36 @@
- name: Copy opensds flexvolume plugin binary file into flexvolume plugin dir
copy:
- src: "{{ nbp_work_dir }}/flexvolume/opensds"
+ src: "{{ nbp_work_dir }}/bin/flexvolume.server.opensds"
dest: "{{ flexvolume_plugin_dir }}/opensds"
+ mode: 0755
+
+- name: Configure opensds endpoint IP in opensds external provisioner plugin
+ lineinfile:
+ dest: "{{ nbp_work_dir }}/provisioner/deploy/configmap.yaml"
+ regexp: '^ opensdsendpoint'
+ line: ' opensdsendpoint: {{ opensds_endpoint }}'
+ backup: yes
+
+- name: Configure opensds auth strategy in opensds external provisioner plugin
+ lineinfile:
+ dest: "{{ nbp_work_dir }}/provisioner/deploy/configmap.yaml"
+ regexp: '^ opensdsauthstrategy'
+ line: ' opensdsauthstrategy: {{ opensds_auth_strategy }}'
+ backup: yes
+
+- name: Configure keystone os auth url in opensds external provisioner plugin
+ lineinfile:
+ dest: "{{ nbp_work_dir }}/provisioner/deploy/configmap.yaml"
+ regexp: '^ osauthurl'
+ line: ' osauthurl: {{ keystone_os_auth_url }}'
+ backup: yes
+ when: opensds_auth_strategy == "keystone"
+
+- name: Prepare and deploy opensds external provisioner plugin
+ shell: |
+ . /etc/profile
+ kubectl create -f deploy/
+ args:
+ chdir: "{{ nbp_work_dir }}/provisioner"
+ ignore_errors: yes
diff --git a/ci/ansible/roles/nbp-installer/scenarios/release.yml b/ci/ansible/roles/nbp-installer/scenarios/release.yml
index 89429d7..b528724 100644
--- a/ci/ansible/roles/nbp-installer/scenarios/release.yml
+++ b/ci/ansible/roles/nbp-installer/scenarios/release.yml
@@ -21,14 +21,15 @@
- name: download and extract the nbp release tarball if not exists
unarchive:
- src={{ nbp_download_url }}
- dest=/tmp/
+ src: "{{ nbp_download_url }}"
+ dest: /tmp/
+ remote_src: yes
when:
- nbpreleasesexisted.stat.exists is undefined or nbpreleasesexisted.stat.exists == false
- name: change the mode of all binary files in nbp release
file:
- path: "{{ nbp_tarball_dir }}/flexvolume"
+ path: "{{ nbp_tarball_dir }}/bin"
mode: 0755
recurse: yes
@@ -36,3 +37,4 @@
copy:
src: "{{ nbp_tarball_dir }}/"
dest: "{{ nbp_work_dir }}"
+ mode: 0755
diff --git a/ci/ansible/roles/nbp-installer/scenarios/repository.yml b/ci/ansible/roles/nbp-installer/scenarios/repository.yml
index fb8059b..0c323d2 100644
--- a/ci/ansible/roles/nbp-installer/scenarios/repository.yml
+++ b/ci/ansible/roles/nbp-installer/scenarios/repository.yml
@@ -15,7 +15,7 @@
---
- set_fact:
go_path: "{{ lookup('env', 'GOPATH') }}"
-
+
- name: check go_path
shell: "{{ item }}"
with_items: