Skip to content

Instantly share code, notes, and snippets.

Avatar

Alan Hinchliff hinchliff

  • Chapel Hill, NC
View GitHub Profile
@hinchliff
hinchliff / c7n_run.py
Created Apr 19, 2019
Run a Cloud Custodian policy file from a Python script. Most useful perhaps to be able to run Cloud Custodian from AWS Lambda.
View c7n_run.py
import os
import logging
from c7n.commands import run
from c7n.config import Config
logger = logging.getLogger()
logger.setLevel(logging.INFO)
# Capture our current directory
THIS_DIR = os.path.dirname(os.path.abspath(__file__))
View ansible_pip_install_vv.log
This file has been truncated, but you can view the full file.
# python3 -m pip install -vv --no-cache-dir ansible==2.10.5
Using pip 21.0 from /usr/local/lib/python3.6/site-packages/pip (python 3.6)
Non-user install because site-packages writeable
Created temporary directory: /tmp/pip-ephem-wheel-cache-h9isolvo
Created temporary directory: /tmp/pip-req-tracker-1nbbe2nv
Initialized build tracking at /tmp/pip-req-tracker-1nbbe2nv
Created build tracker: /tmp/pip-req-tracker-1nbbe2nv
Entered build tracker: /tmp/pip-req-tracker-1nbbe2nv
Created temporary directory: /tmp/pip-install-m1i1i89w
View rya_vm_postboot.sh
#!/bin/bash
# Initial sections copied from Accumulo recipe:
# https://github.com/RENCI-NRIG/exogeni-recipes/tree/master/accumulo/accumulo_exogeni_postboot.txt
############################################################
# Hadoop
############################################################
HADOOP_VERSION=hadoop-2.7.3