Skip to content

Instantly share code, notes, and snippets.

View samjacobson's full-sized avatar

Sam Jacobson samjacobson

  • PeriSentient
  • New Zealand
View GitHub Profile
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
KUBE_TOKEN=$(</var/run/secrets/kubernetes.io/serviceaccount/token)
curl -sSk -H "Authorization: Bearer $KUBE_TOKEN" \
https://$KUBERNETES_SERVICE_HOST:$KUBERNETES_PORT_443_TCP_PORT/api/v1/namespaces/default/pods/$HOSTNAME
@samjacobson
samjacobson / Login.html
Last active August 29, 2015 14:16
GpsEngine VAR xlogin code
<html>
<head>
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery-ajaxtransport-xdomainrequest/1.0.2/jquery.xdomainrequest.min.js"></script>
<script>
$('#login').on('submit', function( event ) {
$('#login_error').text("Logging in...");
$.ajax('http://gps.armadagps.co.nz/myaccount/xlogin', {
data: $(this).serialize(),
type: 'POST',
@samjacobson
samjacobson / gist:4a3bfd66c7d8920ddc54
Created March 9, 2015 02:19
Armadagps.co.nz xlogin code (with raven error collector)
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery-ajaxtransport-xdomainrequest/1.0.2/jquery.xdomainrequest.min.js"></script>
<script src="//cdn.ravenjs.com/1.1.16/raven.min.js"></script>
<script>
Raven.config('http://f451b3265e244e7baf4e297081d5ac0f@sentry.gpsengine.net/5', {
whitelistUrls: [/www\.armadagps\.co\.nz/]
}).install();
$('#login').on('submit', function( event ) {
$('#login_error').text("Logging in...");
$.ajax('http://gps.armadagps.co.nz/myaccount/xlogin', {
@samjacobson
samjacobson / gist:2057940
Created March 17, 2012 11:47
Good comment on marketing
From: http://www.codinghorror.com/blog/2008/10/the-one-thing-every-software-engineer-should-know.html
Marketing is not about deception trickery. There are plenty of marketers that use these tactics to make short-term profits, but they don't pay off in the long term.
Marketing is about understanding your audience - their needs and desires - and communicating the right information about your product to the right segment of that audience. A good marketing team will actively learn about market needs, demand and potential cost ranges and feed this information back into product development.
Unfortunately good marketing is rare - most marketing teams are made up from promoted salespeople, who only know how to close deals by promising more features and larger discounts.
- Twylite on October 23, 2008 10:24 AM