paste post and get
Change-Id: I7ad6f974a4dc9eb7a9c002efb13f776dab852c46
This commit is contained in:
parent
1cbb18788e
commit
dbe5259c84
|
@ -17,12 +17,21 @@
|
|||
register: nodeIP
|
||||
|
||||
|
||||
- name: post to lodget
|
||||
uri:
|
||||
url: http://{{ nodeIP.stdout }}:{{ nodePort.stdout }}
|
||||
method: POST
|
||||
body: "{{ lookup('file','mesos-consul.json') }}"
|
||||
body_format: json
|
||||
headers:
|
||||
Content-Type: "application/json"
|
||||
|
||||
- name: Post the paste
|
||||
command: >
|
||||
curl -vv --silent -d "code=test&language=text&webpage=" http://{{ nodeIP.stdout }}:{{ nodePort.stdout }} 2>&1 |grep Location
|
||||
register: pasteLocationInfo
|
||||
|
||||
- name: Get the pasteUrl
|
||||
command: >
|
||||
cut -d' ' -f3 <<<{{ pasteLocationInfo.stdout }})"
|
||||
register: pasteUrl
|
||||
|
||||
|
||||
- name: Get the paste
|
||||
command: >
|
||||
curl -I {{ pasteUrl.stdout }}
|
||||
register: getPaste
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue