Skip to content

Instantly share code, notes, and snippets.

View smoy's full-sized avatar

Steven Moy smoy

View GitHub Profile
@smoy
smoy / 2023-05-04-thoughts-on-iambic-and-terraform.md
Created May 4, 2023 20:35
Some thoughts regarding why IAMbic when there is Terraform

Preface: I am a developer in the IAMbic repo, so indeed my perspective is biased. Developers have individual preferences. My response is to discuss the design trade/offs why we decided to invest in IAMbic.

“possible with Terraform (albeit an extra step or utilizing something like terragrunt).“

During the design phase, we thought about writing a transpiler to go from YAML to HCL2 to be terraform-compatible. However terraform constraints and our own terraform experience at previous companies have steered us away from that option. Here are a few reasons as to why:

@smoy
smoy / serverless-iam-policy.tf
Created January 26, 2022 23:35
A (hopefully) minimum AWS IAM policy for serverless framework (terraform version)
# Note these are variable you should replace
# MyAccountNumber is your AWS account number
# MyServiceName is the service name you are defining on serverless config
#
# Additional note regarding region like us-west-2, you should change it to fit your situations
resource "aws_iam_policy" "serverless-deployer" {
# TODO: Limit usage to within VPC instead of anywhere
name = "serverless-deployer"
path = "/"
@smoy
smoy / serverless-iam-policy.json
Created January 26, 2022 23:27
A (hopefully) minimum AWS IAM policy for serverless framework
# Note these are variable you should replace
# MyAccountNumber is your AWS account number
# ServerlessServiceName is the service name you are defining on serverless config
#
# Additional note regarding region like us-west-2, you should change it to fit your situations
{
"Version": "2012-10-17",
"Statement": [
{
@smoy
smoy / intel-edison-cmdline.md
Last active August 26, 2015 01:22 — forked from arkival/intel-edison-cmdline.md
C/C++ cross compilation from the command line for the Intel Edison

C/C++ cross compilation from the command line for the Intel Edison

It is not necessary to use the Eclipse environment in order to compile code for the Intel Edison. Command line compilation is possible on all platforms and is relatively straightforward. For linux and OS/X the simplest method is to download the SDK for the respective platform and setup as described below. Although Intel lists SDKs for both 32 and 64 bit Windows, I find it simpler to setup command line compilation from the integrated IOT platform installation.

All three platforms use the GNU compiler tools (gcc, g++, and friends) and the main differences really come down to differences in the command shell usage. Consequently, the procedures have the following common elements.

  1. Install the cross compilation tool chain and library file-system.
  2. Setup the path so that the operating system can find the compilers and other utilities.
  3. Setup environment variables to simplify the command line and tell the compilers where to find librari