Skip to content

Instantly share code, notes, and snippets.

### Keybase proof
I hereby claim:
* I am lnguyen on github.
* I am lnguyen11288 (https://keybase.io/lnguyen11288) on keybase.
* I have a public key whose fingerprint is B390 EBF9 75B9 39FE 7FC8 B0B0 5C81 F578 4D1D BB27
To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am longnguyen11288 on github.
  • I am lnguyen11288 (https://keybase.io/lnguyen11288) on keybase.
  • I have a public key whose fingerprint is B390 EBF9 75B9 39FE 7FC8 B0B0 5C81 F578 4D1D BB27

To claim this, I am signing this object:

@lnguyen
lnguyen / wssb-manifest.yml
Last active August 29, 2015 14:20
wssb-manifest.yml
---
applications:
- name: wssb-pipeline
memory: 128M
instances: 1
host: wssb-pipeline
env:
CREDENTIALS: '{"username": "wssb", "password": "pipeline"}'
SERVICE_NAME: "wssb"
SERVICE_PLAN_NAME: "shared"
training+student2@starkandwayne.com
training+student2@starkandwayne.com
training+student2@starkandwayne.com
training+student2@starkandwayne.com
training+student2@starkandwayne.com
training+student2@starkandwayne.com
# Fix for SD-4531: Remove application specific recipes for database and unility nodes.
@recipes -= app_server_recipes unless @node['instance_role'] =~ /^app|solo|eylocal/
metrics = Yajl::Parser.parse(client.get("#{api_server}/nextgen/clusters/#{cluster_uuid}/metrics").body)
unless metrics["cluster"]["servers"].empty?
pp metrics
puts metrics["cluster"]["servers"]["3d813cbb-47fb-32ba-91df-831e1593ac30"]
#metrics["cluster"]["servers"]
#test_metric metrics["cluster"]["servers"]
end
def to_hash(args)
splited = args.split
if splited.count.even?
returned_hash = Hash.new
splited.each_with_index do |key,index|
if index.even?
returned_hash[key] = splited[index+1]
end
end
else
def application_instances
self.instances.select { |instance| instance[:type] =~ /Application/ }
end
def database_instances
self.instances.select { |instance| instance[:type] =~ /Database/ }
end
def utility_instances
self.instances.select { |instance| instance[:type] =~ /Utility/ }