Skip to content

Instantly share code, notes, and snippets.

@kenperkins
Created January 9, 2014 00:49
Show Gist options
  • Save kenperkins/8327513 to your computer and use it in GitHub Desktop.
Save kenperkins/8327513 to your computer and use it in GitHub Desktop.
Sample Scratch Directory Test
var pkgcloud = require('pkgcloud'),
log = require('../../common/logging'),
_ = require('underscore'),
config = require('../config');
var logger = log.getLogger('debug');
var client = pkgcloud.providers.rackspace.loadbalancer.createClient(config.getConfig());
client.on('log::*', log.logFunction);
client.createLoadBalancer({
name: 'https=test',
protocol: {
name: 'TCP_CLIENT_FIRST',
port: 32129
},
// nodes: [
// {
// "address": "192.168.10.1",
// "port": 80,
// "condition": 'ENABLED'
// },
// {
// "address": "192.168.10.2",
// "port": 80,
// "condition": "ENABLED"
// }
// ],
virtualIps: [
{
type: pkgcloud.providers.rackspace.loadbalancer.VirtualIpTypes.PUBLIC
}
]
}, function (err, lb) {
console.log(JSON.stringify(err, null, ' '));
console.dir(lb);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment