diff options
author | Dan Timoney <dtimoney@att.com> | 2019-03-29 12:58:53 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-03-29 12:58:53 +0000 |
commit | d6346ad42dca37c99773040d88b19227d80a26a6 (patch) | |
tree | f2fa85ba913cd02173e2a2509b1826bdb2dae9ed /installation/ansible-server/src/main | |
parent | 6dd642bbc3a378c15c7e74f2e1fd8cf9722e4b55 (diff) | |
parent | c11ca8e2ea698fc16f0c2bd368a6de74974ac270 (diff) |
Merge "Add Ansible playbook for PNF software rollback"
Former-commit-id: 8099c4a748356dd67a3fddddc340950439575ad8
Diffstat (limited to 'installation/ansible-server/src/main')
-rw-r--r-- | installation/ansible-server/src/main/Playbooks/ansible_huawei_rollback@0.00.yml | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/installation/ansible-server/src/main/Playbooks/ansible_huawei_rollback@0.00.yml b/installation/ansible-server/src/main/Playbooks/ansible_huawei_rollback@0.00.yml new file mode 100644 index 00000000..ef56c54f --- /dev/null +++ b/installation/ansible-server/src/main/Playbooks/ansible_huawei_rollback@0.00.yml @@ -0,0 +1,21 @@ +---
+- hosts: all
+ tasks:
+ - name: create a temporary file for additional data
+ file:
+ path: /tmp/tmp-{{Id}}
+ state: touch
+ become: false
+
+ - name: prepare additional data
+ shell: echo {{additionalData}} > /tmp/tmp-{{Id}}
+ become: false
+
+ - name: execute rollback operation
+ shell: ./swm/rollback.sh {{pnfId}} {{oldSwVersion}} /tmp/tmp-{{Id}}
+
+ - name: remove the temporary file
+ file:
+ path: /tmp/tmp-{{Id}}
+ state: absent
+ become: false
|