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
#cloud-config | |
# Upgrade the instance on first boot | |
# (ie run apt-get upgrade) | |
# | |
# Default: false | |
# Aliases: apt_upgrade | |
package_upgrade: true | |
# Install additional packages on first boot |
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
# | |
# Given the ID of an Amazon public AMI in one region, figure out what the | |
# equivalent AMI IDs are for that same AMI in all other regions known. | |
# If that AMI isn't defined in a region, it prints the region's name, but | |
# comments it out. | |
# | |
from __future__ import print_function | |
import boto3 |
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
// | |
// Lambda's timeout needs to be >5 seconds, 10 should do | |
// | |
var startedAt = new Date(); | |
var interval = setInterval(function () { | |
console.log(startedAt, new Date()); | |
}, 1000); |
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
public class DatabaseDeleter | |
{ | |
private readonly ISessionFactory _configuration; | |
private static readonly string[] _ignoredTables = new[] { "sysdiagrams", "usd_AppliedDatabaseScript" }; | |
private static string[] _tablesToDelete; | |
private static string _deleteSql; | |
private static object _lockObj = new object(); | |
private static bool _initialized; | |
public DatabaseDeleter(ISessionFactory sessionSource) |