Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 39 additions & 40 deletions .tflint.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ plugin "aws" {
}

config {
#Enables module inspection
module = false
force = false
# Enables module inspection (Updated to the correct attribute)
call_module_type = "none"
force = false
}

# Required that all AWS resources have specified tags.
Expand All @@ -19,94 +19,93 @@ rule "aws_resource_missing_tags" {
]
}

# Disallow deprecated (0.11-style) interpolation
# Disallow deprecated (0.11-style) interpolation.
rule "terraform_deprecated_interpolation" {
enabled = true
enabled = true
}

# Disallow legacy dot index syntax.
rule "terraform_deprecated_index" {
enabled = true
enabled = true
}

# Disallow variables, data sources, and locals that are declared but never used.
rule "terraform_unused_declarations" {
enabled = true
enabled = true
}

# Disallow // comments in favor of #.
rule "terraform_comment_syntax" {
enabled = false
enabled = false
}

# Disallow output declarations without description.
rule "terraform_documented_outputs" {
enabled = true
enabled = true
}

# Disallow variable declarations without description.
rule "terraform_documented_variables" {
enabled = true
enabled = true
}

# Disallow variable declarations without type.
rule "terraform_typed_variables" {
enabled = true
enabled = true
}

# Disallow specifying a git or mercurial repository as a module source without pinning to a version.
rule "terraform_module_pinned_source" {
enabled = true
enabled = true
}

# Enforces naming conventions
# Enforces naming conventions.
rule "terraform_naming_convention" {
enabled = true
enabled = true

#Require specific naming structure
variable {
format = "snake_case"
}
# Require specific naming structure.
variable {
format = "snake_case"
}

locals {
format = "snake_case"
}
locals {
format = "snake_case"
}

output {
format = "snake_case"
}
output {
format = "snake_case"
}

#Allow any format
resource {
format = "none"
}
# Allow any format.
resource {
format = "none"
}

module {
format = "none"
}

data {
format = "none"
}
module {
format = "none"
}

data {
format = "none"
}
}

# Disallow terraform declarations without require_version.
rule "terraform_required_version" {
enabled = true
enabled = true
}

# Require that all providers have version constraints through required_providers.
rule "terraform_required_providers" {
enabled = true
enabled = true
}

# Ensure that a module complies with the Terraform Standard Module Structure
# Ensure that a module complies with the Terraform Standard Module Structure.
rule "terraform_standard_module_structure" {
enabled = true
enabled = true
}

# terraform.workspace should not be used with a "remote" backend with remote execution.
rule "terraform_workspace_remote" {
enabled = true
enabled = true
}
10 changes: 8 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,17 +72,23 @@ No modules.
| Name | Type |
|------|------|
| [helm_release.sonarqube](https://registry.terraform.io/providers/hashicorp/helm/latest/docs/resources/release) | resource |
| [kubernetes_manifest.migration_job](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/manifest) | resource |
| [kubernetes_namespace.sonarqube](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/namespace) | resource |
| [random_password.monitoringPasscode](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/password) | resource |
| [random_password.postgresql_password](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/password) | resource |
| [random_password.sonarqube_password](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/password) | resource |

## Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_chart_version"></a> [chart\_version](#input\_chart\_version) | Version of the Jenkins chart that will be used to deploy Jenkins application. | `string` | `"10.6.1"` | no |
| <a name="input_chart_version"></a> [chart\_version](#input\_chart\_version) | Version of the Jenkins chart that will be used to deploy Jenkins application. | `string` | `"2025.2.0"` | no |
| <a name="input_namespace"></a> [namespace](#input\_namespace) | Name of the Kubernetes namespace where the Jenkins deployment will be deployed. | `string` | `"sonarqube"` | no |
| <a name="input_sonarqube_config"></a> [sonarqube\_config](#input\_sonarqube\_config) | Specify the configuration settings for Sonarqube, including the hostname, storage options, and custom YAML values. | `any` | <pre>{<br> "grafana_monitoring_enabled": false,<br> "hostname": "",<br> "postgresql_external_server_url": "",<br> "postgresql_password_external": "",<br> "postgresql_volume_size": "",<br> "sonarqube_volume_size": "",<br> "storage_class_name": "",<br> "values_yaml": ""<br>}</pre> | no |
<<<<<<< HEAD
| <a name="input_sonarqube_config"></a> [sonarqube\_config](#input\_sonarqube\_config) | Specify the configuration settings for Sonarqube, including the hostname, storage options, and custom YAML values. | `any` | <pre>{<br/> "grafana_monitoring_enabled": false,<br/> "hostname": "",<br/> "postgresql_external_server_url": "",<br/> "postgresql_password_external": "",<br/> "postgresql_volume_size": "",<br/> "sonarqube_volume_size": "",<br/> "storage_class_name": "",<br/> "updateExistingSonarqube": false,<br/> "values_yaml": ""<br/>}</pre> | no |
=======
| <a name="input_sonarqube_config"></a> [sonarqube\_config](#input\_sonarqube\_config) | Specify the configuration settings for Sonarqube, including the hostname, storage options, and custom YAML values. | `any` | <pre>{<br/> "grafana_monitoring_enabled": false,<br/> "hostname": "",<br/> "postgresql_external_server_url": "",<br/> "postgresql_password_external": "",<br/> "postgresql_volume_size": "",<br/> "sonarqube_volume_size": "",<br/> "storage_class_name": "",<br/> "values_yaml": ""<br/>}</pre> | no |
>>>>>>> 2d71186b50e076f45ab7e6a587037b5bb0c435ff

## Outputs

Expand Down
3 changes: 1 addition & 2 deletions examples/complete/aws/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,7 @@ No requirements.

| Name | Source | Version |
|------|--------|---------|

| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.0.1 |
| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.1.0 |

## Resources

Expand Down
9 changes: 5 additions & 4 deletions examples/complete/aws/helm/values.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
resources:
limits:
cpu: 500m
memory: 2Gi
cpu: 700m
memory: 6144M
requests:
cpu: 200m
memory: 1.5Gi
cpu: 300m
memory: 2048M

affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
Expand Down
14 changes: 10 additions & 4 deletions examples/complete/aws/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,24 @@ locals {
Department = "Engineering"
}
}

module "sonarqube" {
source = "squareops/sonarqube/kubernetes"
version = "3.0.1"
source = "squareops/sonarqube/kubernetes"
version = "3.1.1"
sonarqube_config = {
hostname = "sonarqube.squareops.in"
values_yaml = file("./helm/values.yaml")
storage_class_name = "gp2"
sonarqube_volume_size = "5Gi"
postgresql_volume_size = "20Gi"
postgresql_volume_size = "10Gi"
grafana_monitoring_enabled = false
monitoringPasscode = ""
postgresql_password_external = ""
postgresql_external_server_url = ""
sonarqube_password = "xxxxx"

updateExistingSonarqube = false # if you have existing sonarqube and want to upgrade,then enable it.
updateExistingSonarqubePassword = false #if you want to update password,enable it and pass sonarqube_current_password(old),sonarqube_password(new)
sonarqube_current_password = "xxxxxx" # if you upgrade sonarqube then you have to provide your previous sonarqube password ##Secret name=sonarqube-sonarqube-admin-password
postgresql_current_password = "xxxxxxx" # if you upgrade sonarqube then you have to provide your previous postgresql password ##Secret name=sonarqube-postgresql
}
}
2 changes: 1 addition & 1 deletion examples/complete/azure/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ No requirements.

| Name | Source | Version |
|------|--------|---------|
| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.0.1 |
| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.1.0 |

## Resources

Expand Down
23 changes: 15 additions & 8 deletions examples/complete/azure/main.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
locals {
name = "sonarqube"
name = ""
region = ""
environment = "prod"
environment = ""
additional_tags = {
Owner = "organization_name"
Expires = "Never"
Expand All @@ -10,16 +10,23 @@ locals {
}

module "sonarqube" {
source = "squareops/sonarqube/kubernetes"
version = "3.0.1"
source = "squareops/sonarqube/kubernetes"
version = "3.1.1"
sonarqube_config = {
hostname = "sonarqube.skaf.squareops.in"
hostname = "sonarqube.squareops.in"
values_yaml = file("./helm/values.yaml")
storage_class_name = "infra-service-sc"
storage_class_name = "gp2"
sonarqube_volume_size = "5Gi"
postgresql_volume_size = "20Gi"
postgresql_volume_size = "10Gi"
grafana_monitoring_enabled = false
postgresql_password_external = "admin"
monitoringPasscode = ""
postgresql_password_external = ""
postgresql_external_server_url = ""
sonarqube_password = ""

updateExistingSonarqube = false # if you have existing sonarqube and want to upgrade,then enable it.
updateExistingSonarqubePassword = false #if you want to update password,enable it and pass sonarqube_current_password(old),sonarqube_password(new)
sonarqube_current_password = "xxxxxx" # if you upgrade sonarqube then you have to provide your previous sonarqube password ##Secret name=sonarqube-sonarqube-admin-password
postgresql_current_password = "xxxxxxx" # if you upgrade sonarqube then you have to provide your previous postgresql password ##Secret name=sonarqube-postgresql
}
}
2 changes: 1 addition & 1 deletion examples/complete/gcp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ No requirements.

| Name | Source | Version |
|------|--------|---------|
| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.0.1 |
| <a name="module_sonarqube"></a> [sonarqube](#module\_sonarqube) | squareops/sonarqube/kubernetes | 3.1.0 |

## Resources

Expand Down
17 changes: 12 additions & 5 deletions examples/complete/gcp/main.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
locals {
name = "sonarqube"
name = ""
region = ""
environment = "prod"
environment = ""
additional_tags = {
Owner = "organization_name"
Expires = "Never"
Expand All @@ -10,16 +10,23 @@ locals {
}

module "sonarqube" {
source = "squareops/sonarqube/kubernetes"
version = "3.0.1"
source = "squareops/sonarqube/kubernetes"
version = "3.1.1"
sonarqube_config = {
hostname = "sonarqube.squareops.in"
values_yaml = file("./helm/values.yaml")
storage_class_name = "gp2"
sonarqube_volume_size = "5Gi"
postgresql_volume_size = "20Gi"
postgresql_volume_size = "10Gi"
grafana_monitoring_enabled = false
monitoringPasscode = ""
postgresql_password_external = ""
postgresql_external_server_url = ""
sonarqube_password = ""

updateExistingSonarqube = false # if you have existing sonarqube and want to upgrade,then enable it.
updateExistingSonarqubePassword = false #if you want to update password,enable it and pass sonarqube_current_password(old),sonarqube_password(new)
sonarqube_current_password = "xxxxxx" # if you upgrade sonarqube then you have to provide your previous sonarqube password ##Secret name=sonarqube-sonarqube-admin-password
postgresql_current_password = "xxxxxxx" # if you upgrade sonarqube then you have to provide your previous postgresql password ##Secret name=sonarqube-postgresql
}
}
Loading