Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc41b781

Browse files
committed
remove default values
1 parent6b65515 commitc41b781

File tree

2 files changed

+55
-79
lines changed

2 files changed

+55
-79
lines changed

‎terraform/aws/terraform.tfvars.example‎

Lines changed: 54 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -5,73 +5,65 @@
55
# -------------------------
66

77
# SSH key for EC2 access (create in AWS Console or CLI)
8-
#ssh_key_name = "your-key-name"
9-
10-
11-
# AWS SETTINGS
12-
# -------------------------
8+
# ssh_key_name = "your-key-name"
139

1410
# AWS region
15-
aws_region = "us-east-1"
11+
#aws_region = "us-east-1"
1612

17-
# Environment
18-
#environment = "production"
13+
# Environment name
14+
#environment = "production"
1915

20-
#instance_type = "t3.medium"
16+
# EC2 instance type
17+
# instance_type = "t3.medium"
2118

2219
# EBS volume size for data (GiB)
23-
#data_volume_size = 50
20+
#data_volume_size = 50
2421

2522
# Storage types
2623
# data_volume_type = "gp3" # gp3 (SSD), st1 (HDD throughput optimized, min 125 GiB), sc1 (HDD cold, min 125 GiB)
2724
# root_volume_type = "gp3" # gp3 (SSD), gp2 (older SSD)
2825

29-
30-
# SECURITY
31-
# -------------------------
26+
# Grafana admin password
27+
# grafana_password = "YourSecurePassword123!"
3228

3329
# CIDR blocks for SSH access (restrict to your IP in production)
34-
#allowed_ssh_cidr = [
35-
# "0.0.0.0/0" # WARNING: Allows access from anywhere
36-
# # "203.0.113.0/24" # Replace with your office/VPN IP
37-
#]
30+
#allowed_ssh_cidr = [
31+
#"0.0.0.0/0" # WARNING: Allows access from anywhere
32+
## "203.0.113.0/24" # Replace with your office/VPN IP
33+
#]
3834

3935
# CIDR blocks for Grafana access (restrict to your IP in production)
40-
#allowed_cidr_blocks = [
41-
# "0.0.0.0/0" # WARNING: Allows access from anywhere
42-
# # "203.0.113.0/24" # Replace with your office/VPN IP
43-
#]
36+
#allowed_cidr_blocks = [
37+
#"0.0.0.0/0" # WARNING: Allows access from anywhere
38+
## "203.0.113.0/24" # Replace with your office/VPN IP
39+
#]
4440

4541
# Allocate Elastic IP for stable address
46-
#use_elastic_ip = true
47-
48-
49-
# POSTGRESQL MONITORING
50-
# -------------------------
51-
52-
# PostgreSQL instances to monitor
53-
#monitoring_instances = [
54-
# {
55-
# name = "production-db"
56-
# conn_str = "postgresql://monitor:password@db.example.com:5432/postgres"
57-
# environment = "production"
58-
# cluster = "main"
59-
# node_name = "primary"
60-
# },
61-
# {
62-
# name = "production-replica"
63-
# conn_str = "postgresql://monitor:password@replica.example.com:5432/postgres"
64-
# environment = "production"
65-
# cluster = "main"
66-
# node_name = "replica-1"
67-
# }
68-
#]
42+
# use_elastic_ip = true
6943

7044

7145
# OPTIONAL PARAMETERS
7246
# -------------------------
7347

74-
# PostgresAI API key (for uploading reports to cloud)
48+
# PostgreSQL instances to monitor (optional, can be empty for initial setup)
49+
# monitoring_instances = [
50+
# {
51+
# name = "production-db"
52+
# conn_str = "postgresql://monitor:password@db.example.com:5432/postgres"
53+
# environment = "production"
54+
# cluster = "main"
55+
# node_name = "primary"
56+
# },
57+
# {
58+
# name = "production-replica"
59+
# conn_str = "postgresql://monitor:password@replica.example.com:5432/postgres"
60+
# environment = "production"
61+
# cluster = "main"
62+
# node_name = "replica-1"
63+
# }
64+
# ]
65+
66+
# PostgresAI API key (optional, for uploading reports to cloud)
7567
#
7668
# How to get API key:
7769
# 1. Register at https://console.postgres.ai
@@ -81,33 +73,27 @@ aws_region = "us-east-1"
8173
# If not set, reports will be generated locally without upload
8274
# postgres_ai_api_key = "your-api-key-here"
8375

84-
# Grafana admin password (defaults to 'demo')
85-
# grafana_password = "YourSecurePassword123!"
86-
87-
# Enable demo database (for testing)
76+
# Enable demo database (optional, for testing)
8877
# enable_demo_db = false
8978

9079

9180
# CONFIGURATION EXAMPLES
9281
# -------------------------
9382

94-
# Minimal configuration (for testing):
95-
# ------------------------------------
96-
# instance_type = "t3.medium"
97-
# data_volume_size = 50
98-
# enable_demo_db = true
99-
# monitoring_instances = []
83+
# Testing with demo database:
84+
# ----------------------------
85+
# Leave monitoring_instances commented out
86+
# Set: enable_demo_db = true (optional parameter)
10087

101-
# Production configuration:
102-
# -------------------------
103-
# instance_type = "t3.xlarge"
104-
# data_volume_size = 200
105-
# allowed_ssh_cidr = ["10.0.0.0/8"]
106-
# allowed_cidr_blocks = ["10.0.0.0/8"]
107-
# use_elastic_ip = true
108-
109-
# Minimal configuration (dev/test):
110-
# ----------------------------------
111-
# instance_type = "t3.small" # WARNING: May be slow for production use
112-
# data_volume_size = 30
113-
# use_elastic_ip = false
88+
# Production with multiple databases:
89+
# ------------------------------------
90+
# Uncomment and fill monitoring_instances with your databases
91+
# Set: instance_type = "t3.xlarge" for better performance
92+
# Set: data_volume_size = 200 for more storage
93+
# Restrict: allowed_ssh_cidr and allowed_cidr_blocks to your network
94+
95+
# Development/staging:
96+
# --------------------
97+
# Set: instance_type = "t3.small" (may be slow)
98+
# Set: data_volume_size = 30 (minimal storage)
99+
# Set: use_elastic_ip = false (save costs)

‎terraform/aws/variables.tf‎

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,31 @@
11
variable"aws_region" {
22
description="AWS region"
33
type=string
4-
default="us-east-1"
54
}
65

76
variable"environment" {
87
description="Environment name"
98
type=string
10-
default="production"
119
}
1210

1311
variable"instance_type" {
1412
description="EC2 instance type"
1513
type=string
16-
default="t3.medium"
1714
}
1815

1916
variable"data_volume_size" {
2017
description="Size of EBS data volume in GiB"
2118
type=number
22-
default=50
2319
}
2420

2521
variable"data_volume_type" {
2622
description="EBS volume type for data disk (gp3 for SSD, st1 for HDD throughput optimized, sc1 for HDD cold)"
2723
type=string
28-
default="gp3"
2924
}
3025

3126
variable"root_volume_type" {
3227
description="EBS volume type for root disk (gp3 for SSD, gp2 for older SSD)"
3328
type=string
34-
default="gp3"
3529
}
3630

3731
variable"ssh_key_name" {
@@ -42,25 +36,21 @@ variable "ssh_key_name" {
4236
variable"allowed_ssh_cidr" {
4337
description="CIDR blocks allowed for SSH access"
4438
type=list(string)
45-
default=["0.0.0.0/0"]
4639
}
4740

4841
variable"allowed_cidr_blocks" {
4942
description="CIDR blocks allowed for Grafana access"
5043
type=list(string)
51-
default=["0.0.0.0/0"]
5244
}
5345

5446
variable"use_elastic_ip" {
5547
description="Allocate Elastic IP for stable address"
5648
type=bool
57-
default=true
5849
}
5950

6051
variable"grafana_password" {
61-
description="Grafana admin password (optional, defaults to 'demo')"
52+
description="Grafana admin password"
6253
type=string
63-
default="demo"
6454
sensitive=true
6555
}
6656

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp