Skip to content

Commit

Permalink
Easier dev setup
Browse files Browse the repository at this point in the history
  • Loading branch information
krystian-panek-vmltech committed Nov 28, 2023
1 parent 2d2616e commit 3458365
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 4 deletions.
13 changes: 13 additions & 0 deletions dev_overrides.tfrc.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
provider_installation {

dev_overrides {
"registry.terraform.io/wttech/aem" = "/Users/krystian.panek/go/bin"
"registry.terraform.io/hashicorp/aws" = "/Users/krystian.panek/go/bin"
"registry.terraform.io/hashicorp/tls" = "/Users/krystian.panek/go/bin"
}

# For all other providers, install them directly from their origin provider
# registries as normal. If you omit this, Terraform will _only_ use
# the dev_overrides block, and so no other providers will be available.
direct {}
}
1 change: 1 addition & 0 deletions develop.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

#!/bin/bash

RED='\033[0;31m'
Expand Down
5 changes: 3 additions & 2 deletions examples/aws_ssh/aws.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ resource "aws_iam_instance_profile" "aem_ec2" {

resource "aws_iam_role" "aem_ec2" {
name = "${local.workspace}_aem_ec2"
assume_role_policy = <<EOF
assume_role_policy = trimspace(<<EOF
{
"Version": "2012-10-17",
"Statement": {
Expand All @@ -47,7 +47,8 @@ resource "aws_iam_role" "aem_ec2" {
"Action": "sts:AssumeRole"
}
}
EOF
EOF
)
tags = local.tags
}

Expand Down
3 changes: 3 additions & 0 deletions examples/aws_ssh/ec2-key.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

ssh-keygen -P "" -t rsa -b 4096 -m pem -f ec2-key.cer
5 changes: 3 additions & 2 deletions examples/aws_ssm/aws.tf
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ resource "aws_iam_instance_profile" "aem_ec2" {

resource "aws_iam_role" "aem_ec2" {
name = "${local.workspace}_aem_ec2"
assume_role_policy = <<EOF
assume_role_policy = trimspace(<<EOF
{
"Version": "2012-10-17",
"Statement": {
Expand All @@ -35,7 +35,8 @@ resource "aws_iam_role" "aem_ec2" {
"Action": "sts:AssumeRole"
}
}
EOF
EOF
)
tags = local.tags
}

Expand Down

0 comments on commit 3458365

Please sign in to comment.