Skip to content

Instantly share code, notes, and snippets.

@hagbarddenstore
Forked from anonymous/gist:4be1e29b5ebf14d39b59
Last active October 19, 2015 10:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save hagbarddenstore/ccef5d3bf7fd9db0612f to your computer and use it in GitHub Desktop.
Save hagbarddenstore/ccef5d3bf7fd9db0612f to your computer and use it in GitHub Desktop.
---
- hosts: all
sudo: true
vars_files:
- vars.yml
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: "{\"name\": \"{{ host_variable }}\"}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment