This file contains hidden or 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
<?php | |
require_once "aws.phar"; | |
//設定 | |
$access_key = "<ACCESS_KEY>"; | |
$secret_key = "<SECRET_KEY>"; | |
$distribution_id = "<DISTRIBUTION_ID>"; | |
$paths = array("/img/a.png",); |
This file contains hidden or 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
# RTX1200 Rev.10.01.65 (Tue Oct 13 12:23:48 2015) | |
# Memory 128Mbytes, 3LAN, 1BRI | |
# main: RTX1200 ver=b0 serial=XXXXXXXX MAC-Address=XX:XX:XX:XX:XX:XX MAC-Address=XX:XX:XX:XX:XX:XX MAC-Address=XX:XX:XX:XX:XX:XX | |
# Reporting Date: Aug 7 17:18:23 2016 | |
# セキュリティクラス 3(シリアルからのみログイン許可) | |
# Telnet SSHコマンド使用不可 | |
security class 3 on off off | |
# タイムゾーンはJST |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
# Rubyで重い処理を並列動作させるサンプルスクリプトです。 | |
require 'parallel' | |
require 'pp' | |
# 開始時刻と終了時刻を記録するクラス | |
class RecordUtil |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
# ElasticCacheにmemcacheクラスタを構築するスクリプトです。 | |
# 要 AWS SDK for Ruby V2 | |
require 'aws-sdk-core' | |
require 'yaml' | |
require 'pp' | |
config = YAML.load(File.read('config.yml')) |
This file contains hidden or 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
{ | |
"AWSTemplateFormatVersion": "2010-09-09", | |
"Resources": { | |
"rdsauroratest": { | |
"Type": "AWS::RDS::DBInstance", | |
"Properties": { | |
"AllocatedStorage": "0", | |
"AllowMajorVersionUpgrade": "false", | |
"AutoMinorVersionUpgrade": "true", | |
"DBInstanceClass": "db.r3.large", |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
# | |
# RDSのログファイルをダウンロードするスクリプトです。 | |
# MySQLでテストしてます。 | |
# 要 AWS SDK for Ruby V2 | |
# | |
require 'aws-sdk-core' | |
require 'yaml' | |
require 'pp' |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
# | |
# 自分が所有するSnapShotで、AMIがないものを探索するスクリプトです。 | |
# 要 AWS SDK for Ruby V2 | |
# | |
require 'aws-sdk-core' | |
require 'yaml' | |
require 'pp' |
This file contains hidden or 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/sh | |
# http://askubuntu.com/questions/1705/how-can-i-create-a-select-menu-in-a-shell-scriptより参照 | |
#メインメニュー | |
show_menu(){ | |
NORMAL=`echo "\033[m"` | |
MENU=`echo "\033[36m"` #Blue | |
NUMBER=`echo "\033[33m"` #yellow | |
FGRED=`echo "\033[41m"` | |
RED_TEXT=`echo "\033[31m"` |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
require 'aws-sdk-core' | |
require 'yaml' | |
require 'pp' | |
config=YAML.load(File.read("config.yml")) | |
Aws.config[:credentials] = Aws::Credentials.new(config['access_key_id'],config['secret_access_key']) | |
ec2=Aws::EC2::Client.new(region:config['region']) |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
# | |
# ELBを作成するスクリプトです。ついでにSSL証明書もセットしますが、EC2をぶら下げるまではしません。 | |
# 要 AWS SDK for Ruby V2 | |
require 'aws-sdk-core' | |
require 'yaml' | |
require 'pp' | |
config = YAML.load(File.read("config.yml")) |