Skip to content

Instantly share code, notes, and snippets.

View prune998's full-sized avatar
🔧
Coding

Prune Sebastien THOMAS prune998

🔧
Coding
View GitHub Profile
// _Channels_ are the pipes that connect concurrent
// goroutines. You can send values into channels from one
// goroutine and receive those values into another
// goroutine.
package main
import "fmt"
import "time"
@prune998
prune998 / gist:0aaf992b7aec450abfb0
Created January 22, 2015 13:56
dict in set_fact
- set_fact: action_data="{'action':'one','data':'two'}"
tags:
- deploy_container
- deploy_container_id
- debug: msg="say {{ action_data['action'] }}"
tags:
- deploy_container
- deploy_container_id
This is a working version :
from ansible import utils, errors
import random, string
class LookupModule (object):
""" This lookup generate a UUID of the length specified by the term
Usage:
set_fact: container_id="{{ lookup('uuid',32) }}"