Skip to content

Instantly share code, notes, and snippets.

View tomellis's full-sized avatar

Tom Ellis tomellis

View GitHub Profile
@jpbarto
jpbarto / private-eks-nodes.yaml
Created July 29, 2019 06:44
Private EKS Worker Nodes - CloudFormation
###
#
# CloudFormation Template to create EKS Worker Nodes without access to an IGW
#
# The following CloudFormation template is based upon the AWS-provided CloudFormation template for creating
# EKS worker nodes in your VPC. It differs in that it has user-data modified to configure a node to operate
# within a VPC that has no IGW.
#
# To use this template you will need a VPC with an EKS cluster already deployed and private access enabled.
# You will also need a web proxy configured to allow the worker nodes access to the AWS EKS service API. This
@matthewberryman
matthewberryman / greengrass.service
Last active November 25, 2019 11:42
greengrass systemd
[Unit]
Description=greengrass daemon
After=network.target
[Service]
ExecStart=/greengrass/ggc/core/greengrassd start
Type=simple
RestartSec=2
Restart=always
User=root
var http = require ('https');
var querystring = require ('querystring');
exports.handler = function(event, context) {
console.log(event);
var message = JSON.parse(event.Message);
var color = 'warning';
switch(message.NewStateValue) {
case "OK":
color = 'good';