Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| #! /usr/bin/env bash | |
| # Create the container with a long running process. If PID1 exists before | |
| # we send the exec commands, they will fail because the container is not running | |
| # | |
| CONTAINER_NAME="TEST-`uuidgen`" | |
| curl --silent --unix-socket /var/run/docker.sock "http:/containers/create?name=${CONTAINER_NAME}" -XPOST \ | |
| -H "Content-Type: application/json" \ | |
| -d '{ | |
| "Image": "ruby:latest", |
| #standardSQL | |
| #Top two Hacker News articles by day | |
| WITH TitlesAndScores AS ( | |
| SELECT | |
| ARRAY_AGG(STRUCT(title, | |
| score)) AS titles, | |
| EXTRACT(DATE | |
| FROM | |
| time_ts) AS date | |
| FROM |
| import logging.config | |
| import os | |
| from django.utils.log import DEFAULT_LOGGING | |
| # Disable Django's logging setup | |
| LOGGING_CONFIG = None | |
| LOGLEVEL = os.environ.get('LOGLEVEL', 'info').upper() | |
| logging.config.dictConfig({ |