Skip to content

Instantly share code, notes, and snippets.

View wolfeidau's full-sized avatar
🐺
Building data science projects

Mark Wolfe wolfeidau

🐺
Building data science projects
View GitHub Profile
AWSTemplateFormatVersion: '2010-09-09'
Transform: AWS::Serverless-2016-10-31
Resources:
Function:
Type: AWS::Serverless::Function
Properties:
Handler: handler.Handle
Runtime: python2.7
CodeUri: ../cloudbookmarks.zip
Events:
@wolfeidau
wolfeidau / cloudwatch_alarms_cloudtrail.rb
Created January 6, 2017 03:46
Ruby DSL version of the cloudwatch alarms for cloudtrail template
#!/usr/bin/env ruby
require 'bundler/setup'
require 'cloudformation-ruby-dsl/cfntemplate'
require 'cloudformation-ruby-dsl/spotprice'
require 'cloudformation-ruby-dsl/table'
template do
value AWSTemplateFormatVersion: '2010-09-09'
@wolfeidau
wolfeidau / yarn_build.sh
Created January 4, 2017 02:36
Build file for Yarn, Thanks @deoxxa
#!/bin/sh
set -e
echo "--- Clearing old build contents"
rm -rf build/*
echo "--- Getting yarn image"
docker pull kkarczmarczyk/node-yarn:6.7-slim
@wolfeidau
wolfeidau / embedded_security.md
Created October 26, 2016 18:49
Discussion on security for devices
I'll respond in more detail when I'm on the computer. I strongly agree, at the very minimum:

1. Secure bootloader
2. Lock flash, or better blow JTAG fuse
3. Keep CA certs on device and issue certs using CA to cloud servers
4. use signed OTA payloads, you'll need this if you're doing 1. (edited)

[10:03]  
I learnt the hard way comprising security for usability/product requirements. :disappointed:
@wolfeidau
wolfeidau / docker.md
Last active October 7, 2016 04:36
Docker notes for Ashish.

Get centos, this will grab down centos:latest from docker hub.

docker pull centos

Run a container.

docker run -v $(pwd):/src -it centos /bin/bash
@wolfeidau
wolfeidau / clouformation_stack_facts.py
Created August 26, 2016 03:23
cloudformation plugin for ansible
#!/usr/bin/python
DOCUMENTATION = '''
---
module: cloudformation_stack_facts
short_description: list or describe stacks in cloudformation
notes:
- for details of the parameters and returns see U(http://boto3.readthedocs.org/en/latest/reference/services/cloudformation.html)
description:
- Lists or describes stacks in cloudformation.

Keybase proof

I hereby claim:

  • I am wolfeidau on github.
  • I am wolfeidau (https://keybase.io/wolfeidau) on keybase.
  • I have a public key ASA_a8J3oBKsvIhbZjD8LHZS9t87vPf4yqrwubsxLioJtgo

To claim this, I am signing this object:

@wolfeidau
wolfeidau / notes.md
Created August 6, 2016 07:40
Linux setup notes

Build golang deb file.

tar xvzf go1.7rc5.linux-amd64.tar.gz
mkdir -p root/usr/local root/etc/profile.d
mv go root/usr/local
cat /etc/profile.d/golang.sh << EOF
PATH=$PATH:/usr/local/go/bin
export PATH
EOF
@wolfeidau
wolfeidau / aws_docker_mount.sh
Created May 29, 2016 09:35
Mount a volume for docker images.
(/usr/sbin/blkid -t TYPE=ext4 | grep /dev/xvdk) || (/usr/sbin/wipefs -fa /dev/xvdk && /usr/sbin/mkfs.ext4 /dev/xvdk)
mkdir /mnt/ebs-docker
mount /dev/xvdk /mnt/ebs-docker -t ext4
mkdir /mnt/ebs-docker/docker
ln -s /mnt/ebs-docker/docker /var/lib/docker
@wolfeidau
wolfeidau / wiced.md
Last active May 25, 2016 23:46
Some notes on my Redbear DUO board.

Wiring

Currently this is how I have the DUO Board wired to my ST-LINK V2.

ST-LINK V2             REDBEAR DUO

                       +-------------------+
                       |                   |
                       | D1                |