Skip to content

Instantly share code, notes, and snippets.

@mgedmin
Forked from hagbarddenstore/gist:ccef5d3bf7fd9db0612f
Last active October 19, 2015 10:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mgedmin/457dfe5cb1f2b9d8600b to your computer and use it in GitHub Desktop.
Save mgedmin/457dfe5cb1f2b9d8600b to your computer and use it in GitHub Desktop.
---
- hosts: all
sudo: true
vars_files:
- vars.yml
vars:
body:
name: "{{host_variable}}"
tasks:
- uri:
url: "https://api.serverpilot.io/v1/servers"
user: "{{ spclientid }}"
password: "{{ spapikey }}"
return_content: yes
method: POST
force_basic_auth: yes
HEADER_Content-Type: "application/json"
body: "{{ body | to_json }}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment