Skip to content

Commit 61c8393

Browse files
committed
A few small fixes
1 parent e3e0409 commit 61c8393

File tree

6 files changed

+10
-7
lines changed

6 files changed

+10
-7
lines changed

internal/config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ type aws struct {
7878
Region string
7979
EKS eks
8080
Cognito cognito
81-
S3Hosting s3Hosting `yaml:"s3_hosting"`
81+
S3Hosting s3Hosting `yaml:"s3Hosting"`
8282
Terraform terraform
8383
}
8484

internal/generate/kubernetes/generate.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import (
99
"github.com/commitdev/commit0/internal/config"
1010
"github.com/commitdev/commit0/internal/templator"
1111
"github.com/commitdev/commit0/internal/util"
12+
"github.com/kyokomi/emoji"
1213
"github.com/logrusorgru/aurora"
1314
)
1415

@@ -24,7 +25,7 @@ func Execute(cfg *config.Commit0Config, pathPrefix string) {
2425

2526
pathPrefix = filepath.Join(pathPrefix, "kubernetes/terraform")
2627

27-
log.Println(aurora.Cyan(":alarm_clock: Applying kubernetes configuration..."))
28+
log.Println(aurora.Cyan(emoji.Sprintf(":alarm_clock: Applying kubernetes configuration...")))
2829
util.ExecuteCommand(exec.Command("terraform", "init"), filepath.Join(pathPrefix, "environments/staging"), envars)
2930
util.ExecuteCommand(exec.Command("terraform", "apply", "-auto-approve"), filepath.Join(pathPrefix, "environments/staging"), envars)
3031
}

internal/generate/terraform/generate.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ func Execute(cfg *config.Commit0Config, pathPrefix string) {
8282

8383
pathPrefix = filepath.Join(pathPrefix, "terraform")
8484

85-
log.Println(aurora.Cyan(":alarm_clock: Applying infrastructure configuration..."))
85+
log.Println(aurora.Cyan(emoji.Sprintf(":alarm_clock: Applying infrastructure configuration...")))
8686
util.ExecuteCommand(exec.Command("terraform", "init"), filepath.Join(pathPrefix, "environments/staging"), envars)
8787
util.ExecuteCommand(exec.Command("terraform", "apply", "-auto-approve"), filepath.Join(pathPrefix, "environments/staging"), envars)
8888

templates/commit0/commit0.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ infrastructure:
1515
clusterName: staging
1616
cognito:
1717
enabled: true
18-
s3_hosting:
18+
s3Hosting:
1919
enabled: true
2020

2121
frontend:

templates/terraform/modules/environment/main.tf

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,16 @@ module "kube2iam" {
4444
}
4545

4646
# {{ if .Config.Infrastructure.AWS.Cognito.Enabled }}
47-
resource "cognito" "auth" {
47+
module "cognito" {
48+
source = "../../modules/cognito"
4849
user_pool = var.user_pool
4950
hostname = var.hostname
5051
}
5152
# {{- end}}
5253

5354
# {{ if .Config.Infrastructure.AWS.S3Hosting.Enabled }}
54-
resource "s3_hosting" "assets" {
55+
module "s3_hosting" {
56+
source = "../../modules/s3_hosting"
5557
bucket_name = var.s3_hosting_bucket_name
5658
}
5759
# {{- end}}

templates/terraform/modules/vpc/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ module "vpc" {
55
cidr = "10.20.0.0/16"
66

77
azs = ["${var.region}a", "${var.region}b", "${var.region}c"] # Most regions have 3+ azs
8-
private_subnets = ["10.20.10.0/22", "10.20.14.0/22", "10.20.18.0/22"]
8+
private_subnets = ["10.20.8.0/22", "10.20.12.0/22", "10.20.16.0/22"]
99
public_subnets = ["10.20.41.0/24", "10.20.43.0/24", "10.20.45.0/24"]
1010
database_subnets = ["10.20.60.0/24", "10.20.62.0/24", "10.20.64.0/24"]
1111

0 commit comments

Comments
 (0)