Skip to content

Instantly share code, notes, and snippets.

View hlindberg's full-sized avatar

Henrik Lindberg hlindberg

  • Bebalon Ltd
  • Għarb, Gozo, Malta
  • X @hel
View GitHub Profile
@hlindberg
hlindberg / gist:660cfacf68860c1ae96d
Created July 14, 2015 17:42
load balanser in honeydew with $ variables

Load Balancer Example (puppetized)

The first part - ChangeRequest is a generic plan that holds on to a set of values of type T (given when plan is instantiated), and emits the changed set whenever it changes.

type AddRemove = Enum['add', 'remove']
type ChangeRequest[T] = Struct[{'kind' => AddRemove, 'value' => T }]
@hlindberg
hlindberg / gist:ef417f3fb8778740f2a2
Last active August 29, 2015 14:24
Load balancer in Honeydew - $ for variables, no $ for queues

Load Balancer Example (puppetized)

The first part - ChangeRequest is a generic plan that holds on to a set of values of type T (given when plan is instantiated), and emits the changed set whenever it changes.

type AddRemove = Enum['add', 'remove']
type ChangeRequest[T] = Struct[{'kind' => AddRemove, 'value' => T }]
---
packaging_url: 'git://github.com/puppetlabs/packaging.git --branch=master'
packaging_repo: 'packaging'
default_cow: 'base-squeeze-i386.cow'
cows: 'base-CumulusLinux-2.2-amd64.cow base-lucid-i386.cow base-precise-i386.cow base-squeeze-i386.cow base-trusty-i386.cow base-wheezy-i386.cow'
pbuild_conf: '/etc/pbuilderrc'
packager: 'puppet'
gpg_name: 'info@puppetlabs.com'
gpg_key: '4BD6EC30'
sign_tar: FALSE
If you want to install Geppetto into your Eclipse IDE, you can do so by giving the Eclipse update manager this repository URL
http://download.cloudsmith.com/geppetto/updates
Please note that this URL is for use by a download manager - it is not meaningful to visit this URL with a browser.
@hlindberg
hlindberg / geppetto.cquery
Created March 24, 2011 23:22
geppetto.cquery - feed this to Buckminster to set up Eclipse Workspace and Target Platform
<?xml version="1.0" encoding="UTF-8"?>
<cq:componentQuery xmlns:cq="http://www.eclipse.org/buckminster/CQuery-1.0" resourceMap="geppetto.rmap">
<cq:rootRequest name="org.cloudsmith.geppetto.product" componentType="eclipse.feature"/>
<cq:property key="source.repository.url" value="git://github.com/cloudsmith/geppetto.git"/>
<cq:property key="target.arch" value="*"/>
<cq:property key="target.os" value="*"/>
<cq:property key="target.ws" value="*"/>
<cq:advisorNode useMaterialization="false" useTargetPlatform="false"/>
</cq:componentQuery>
@hlindberg
hlindberg / hiera.pptp
Created July 11, 2012 12:49
PPTP file describing puppet-hiera functions
<?xml version="1.0" encoding="ASCII"?>
<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:pptp="http://www.cloudsmith.org/geppetto/1.0.0/PPTP">
<pptp:PuppetDistribution description="Puppet Plugin" version="1.0.0rc1" label="puppetlabs-hiera-puppet">
<functions documentation="" name="hiera" rValue="true"/>
<functions documentation="" name="hiera_array" rValue="true"/>
<functions documentation="" name="hiera_hash" rValue="true"/>
<functions documentation="" name="hiera_include"/>
</pptp:PuppetDistribution>
</xmi:XMI>
@hlindberg
hlindberg / junoclassic-tweaked.css
Created August 21, 2012 13:10
Eclipse Juno Classic Theme Tweaked to look like Indigo
.MTrimmedWindow {
margin-top: 0px;
margin-bottom: 0px;
margin-left: 2px;
margin-right: 2px;
}
.MPartStack {
swt-tab-renderer: null;
swt-selected-tabs-background: #FFFFFF #E8E8E8 100%;
@hlindberg
hlindberg / gist:3429488
Created August 22, 2012 21:20
crash - geppetto issue 382
Process: Geppetto [12470]
Path: /Users/USER/*/Geppetto.app/Contents/MacOS/Geppetto
Identifier: org.eclipse.eclipse
Version: 3.8 (3.8)
Code Type: X86-64 (Native)
Parent Process: launchd [147]
Date/Time: 2012-08-22 23:07:47.840 +0200
OS Version: Mac OS X 10.7.4 (11E53)
Report Version: 9
@hlindberg
hlindberg / henrik.lindberg.key
Created September 19, 2012 17:36
henrik.lindberg@cloudsmith.com public key
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA6Xn/GNCiRJXWcdYa90ebvf3dFgIy3BDvOag82lSA6X9fbkJWo03VMYu4n90T3DCNLWS0mOc8b16V7aRAXITDhEAmm/K16mTf8CstdNyYf6lh35v4oLtBlva/XuXH0R/pNrpdoBQwxw3eS4h4n5vgzAGT5peHplQ9/uamCQgvIRQl4XLLrps8LyHi5kBA8BZHmOQETVSYK4TlZ2JWF2wnM+j6eeo8cjT9FFyo6nKe8z2glc97M15byAgRopXs3z5X5g29Y32VO4aco04QT/1KoRyhCQkxmwMEBaxqu6d3H0r9/hWvy3ZuQ+yYLKTsxiE0bBhLaOLR8b/COMtQIL+SZQ== henrik.lindberg@cloudsmith.com
./systest.rb -c ~/harness_work/config.yml --puppet "origin/master" --type package --ntp --ntp-server us.pool.ntp.org --root-keys --no-color --xml --debug --tests "template/PassTest.rb" --pkg-repo
Using Config /Users/henrik/harness_work/config.yml
Begin setup/early/00-vmrun.rb
Revert VMs
Skip: Skipping revert VM step
setup/early/00-vmrun.rb skipped in 0.00 seconds
Begin setup/early/01-gen-answer-file.rb
Skip: Skipping PE 2.x answers file generation for non PE tests
setup/early/01-gen-answer-file.rb skipped in 0.00 seconds