This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
opscode_user_secret = Chef::EncryptedDataBagItem.load_secret("#{node[:opscode_user][:secretpath]}") | |
opscode_user_creds = Chef::EncryptedDataBagItem.load("chef_backup", "opscode_user", opscode_user_secret) | |
opscode_user_creds["ssh_key"] | |
opscode_user = encrypted_data_bag_item("chef_backup", "opscode_user") | |
template "/root/.chef/chef_backup_user.pem" do | |
variables(:ssh_key => opscode_user_creds['ssh_key']) | |
source chef_backup_user_pem.erb | |
owner "root" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Homer < RTanque::Bot::Brain | |
NAME = 'MyDriveDestroyer' | |
include RTanque::Bot::BrainHelper | |
def tick! | |
move | |
in_circles | |
fire | |
if someones_close |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[stats] | |
priority = 100 | |
pattern = ^stats\..* | |
retentions = 10:2160,60:10080,600:262974 | |
[deployments] | |
priority = 100 | |
pattern = ^stats\.*\.apps.deployments | |
retentions = 10:262974 | |
[collectd] | |
priority = 100 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_s3_files_for_csv(bucket, type) | |
@csv_data.map do |element| | |
(bucket.objects.with_prefix("#@base_path/#{element[type]}") || []).select do |o| | |
looks_like_a_trip?(o.key) && | |
between_dates?(o.key, @opts[:start_date], @opts[:end_date]) && | |
in_rolling_window?(o.key, element[:loss_date]) | |
end | |
end.flatten | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_s3_files_for_csv(bucket, type) | |
@csv_data.map do |element| | |
(bucket.objects.with_prefix("#@base_path/#{element[type]}") || []).select do |o| | |
looks_like_a_trip?(o.key) && | |
between_dates?(o.key, @opts[:start_date], @opts[:end_date]) && | |
in_rolling_window?(o.key, element[:loss_date]) | |
end | |
end.flatten | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CSV.foreach(csv, headers: :first_row, header_converters: :downcase) do |row| | |
@csv_data << {imei: row['imei'], subscription_id: row['subscription_id'], loss_date: Time.parse(row['loss_date'])} | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@measuring1:/opt/graphite/storage/whisper# whisper-info.py stats/dev/apps/deployments/test.wsp | |
maxRetention: 31536000 | |
xFilesFactor: 0.0 | |
aggregationMethod: sum | |
fileSize: 378432028 | |
Archive 0 | |
retention: 31536000 | |
secondsPerPoint: 1 | |
points: 31536000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
maxRetention: 157784400 | |
xFilesFactor: 0.5 | |
aggregationMethod: average | |
fileSize: 3302620 | |
Archive 0 | |
retention: 21600 | |
secondsPerPoint: 10 | |
points: 2160 | |
size: 25920 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ cassandra-cli | |
Connected to: "Test Cluster" on 127.0.0.1/9160 | |
Welcome to Cassandra CLI version 1.2.6 | |
Type 'help;' or '?' for help. | |
Type 'quit;' or 'exit;' to quit. | |
[default@unknown] use cassandra_test; | |
Authenticated to keyspace: cassandra_test | |
[default@mydrive_test] update column family TripProfiles |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"name": "dev", | |
"columnFamilies": [ | |
{ | |
"name": "AggregateProfiles" | |
}, | |
{ | |
"name": "LinkHistory" | |
}, |
OlderNewer