Skip to content

Instantly share code, notes, and snippets.

View No9's full-sized avatar
🦀
Rusting with a slight chance of code

Anton Whalley No9

🦀
Rusting with a slight chance of code
View GitHub Profile
@No9
No9 / host-multiaction.js
Created April 16, 2014 13:21
A POC for issue. Save it in the test folder next to host.js
var test = require("tap").test;
var assert = require('assert');
var http = require('http');
var httpProxy = require('http-proxy');
// Create an array of selects that harmon will process.
var actions = [];
// Create a simple action
Hours in a year 8765
On demand
$0.154 / Hour = 8765
8765 * 0.127 = 1113.155
$220 $0.127 per Hour 1,349.81 for a Medium Instance
@No9
No9 / hyperscript.js
Last active August 29, 2015 14:24
A tongue in cheek implementation of hyperscript to illustrating a 'pure ui' approach
// Based on http://rauchg.com/2015/pure-ui/
var h = require('hyperscript')
function dashboard(opts){
// with proper access to the layout data
// data CSS media queries can be redundant
if (opts.width > 375) {
return h('div', 'Twitter followers ' + opts.num)
} else {
return h('div', 'Twitter followers ' + (opts.num / 1000) + 'K')
@No9
No9 / installnode.sh
Created September 11, 2015 23:56
Install node on a base illumOS install
#/bin/sh
pkgin in git
pkgin in gcc49
pkgin in gmake
export PATH=$PATH:/opt/local/gcc49/bin
git clone https://github.com/nodejs/node.git
cd node
#Make sure to change version
git checkout v4.0.0
@No9
No9 / sinopia-manifest.xml
Created July 2, 2016 17:18
Sample config for sinopia on openindiana
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<service_bundle type="manifest" name="sinopia">
<service name="site/sinopia" type="service" version="1">
<create_default_instance enabled="true"/>
<single_instance/>
<dependency name="network" grouping="require_all" restart_on="refresh" type="service">
@No9
No9 / helloworld.yaml
Created March 14, 2017 11:35
serverless yaml template for em
# Welcome to Serverless!
#
# This file is the main config file for your service.
# It's very minimal at this point and uses default values.
# You can always add more config options for more control.
# We've included some commented out config examples here.
# Just uncomment any of them to get that config option.
#
# For full config options, check the docs:
# docs.serverless.com
@No9
No9 / iocage-meetup.md
Last active July 21, 2020 03:16
Some notes for the BSD Dublin Meetup 2017-04-20
@No9
No9 / consuld.sh
Last active October 16, 2021 06:41
consuld - a consul daemon config for freebsd
#!/bin/sh
#
# $FreeBSD: releng/11.0/etc/rc.d/consuld 298514 2016-04-23 16:10:54Z lme $
#
# PROVIDE: consuld
# REQUIRE: LOGIN FILESYSTEMS
# KEYWORD: shutdown
. /etc/rc.subr
@No9
No9 / notes.md
Created May 18, 2017 08:11
BSD-Dublin-2017-05-18-Capsicum

Scribble Pad for the May Meetup