Skip to content

Instantly share code, notes, and snippets.

@sbeliakou
Created January 19, 2017 09:27
Show Gist options
  • Save sbeliakou/6831e0d64cecfc232902d6c4d10c2480 to your computer and use it in GitHub Desktop.
Save sbeliakou/6831e0d64cecfc232902d6c4d10c2480 to your computer and use it in GitHub Desktop.

Testing playbook:

test.yml

- hosts: localhost
  connection: local

  tasks:
  - timetest:

lib/timetest.py

#!/usr/bin/python

import datetime
import json

date = str(datetime.datetime.now())
print json.dumps({
    "time" : date
})

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment