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
#!/bin/bash | |
# | |
# this script will attempt to detect any ephemeral drives on an EC2 node and create a RAID-0 stripe | |
# mounted at /mnt. It should be run early on the first boot of the system. | |
# | |
# Beware, This script is NOT fully idempotent. | |
# | |
METADATA_URL_BASE="http://169.254.169.254/2012-01-12" | |
RAID_MOUNT_DIR="/mnt/md0" |
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
#!/usr/bin/env python | |
# ddb_lsi_example: A sample program to show how to use Local Secondary Indexes | |
# in DynamoDB, using Python and boto3. | |
# | |
# Copyright 2016 Parijat Mishra | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 |
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
import boto3 | |
client = boto3.client('cloudsearch') | |
# List properties of all domains | |
print "List all domains" | |
domains = [] | |
response = client.describe_domains() | |
for domain in response['DomainStatusList']: | |
domain_name = domain['DomainName'] |