-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/felipmiguel/batec-ossrdbms-…
- Loading branch information
Showing
21 changed files
with
385 additions
and
169 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"ConnectionStrings": { | ||
"DefaultConnection": "Server=psqlf-batec-ossrdbms-demo-uak-dev.postgres.database.azure.com;Database=psqlfdb-batec-ossrdbms-demo-dev;Ssl Mode=Require;Port=5432;Trust Server Certificate=true;User Id=fmiguel_outlook.com#EXT#@fmigueloutlook.onmicrosoft.com;" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Terraform module for Azure Application Insights configuration | ||
|
||
This module configures an Azure Application Insights instance with Terraform. | ||
|
||
## Resources | ||
|
||
[What is Azure Application Insights](https://aka.ms/nubesgen-app-insights) | ||
[Terraform Azure Application Insights reference](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/application_insights) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
terraform { | ||
required_providers { | ||
azurecaf = { | ||
source = "aztfmod/azurecaf" | ||
version = "1.2.24" | ||
} | ||
} | ||
} | ||
|
||
resource "azurecaf_name" "application_insights" { | ||
name = var.application_name | ||
resource_type = "azurerm_application_insights" | ||
suffixes = [var.environment] | ||
} | ||
|
||
resource "azurerm_application_insights" "application_insights" { | ||
name = azurecaf_name.application_insights.result | ||
location = var.location | ||
resource_group_name = var.resource_group | ||
application_type = "other" | ||
|
||
tags = { | ||
"environment" = var.environment | ||
"application-name" = var.application_name | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
output "azure_application_insights_instrumentation_key" { | ||
value = azurerm_application_insights.application_insights.instrumentation_key | ||
description = "The Azure Application Insights instrumentation key" | ||
} | ||
|
||
output "azure_application_insights_connection_string" { | ||
value = azurerm_application_insights.application_insights.connection_string | ||
description = "The Azure Application Insights connection string" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
variable "resource_group" { | ||
type = string | ||
description = "The resource group" | ||
default = "" | ||
} | ||
|
||
variable "application_name" { | ||
type = string | ||
description = "The name of your application" | ||
default = "" | ||
} | ||
|
||
variable "environment" { | ||
type = string | ||
description = "The environment (dev, test, prod...)" | ||
default = "dev" | ||
} | ||
|
||
variable "location" { | ||
type = string | ||
description = "The Azure region where all resources in this example should be created" | ||
default = "" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,28 @@ | ||
output "application_pgsql_name" { | ||
value = azurecaf_name.pgsql_application.result | ||
description = "The application name generated by the Azure Cloud Adoption Framework." | ||
} | ||
# output "application_pgsql_name" { | ||
# value = azurecaf_name.pgsql_application.result | ||
# description = "The application name generated by the Azure Cloud Adoption Framework." | ||
# } | ||
|
||
output "application_mysql_name" { | ||
value = azurecaf_name.mysql_application.result | ||
description = "The application name generated by the Azure Cloud Adoption Framework." | ||
} | ||
# output "application_mysql_name" { | ||
# value = azurecaf_name.mysql_application.result | ||
# description = "The application name generated by the Azure Cloud Adoption Framework." | ||
# } | ||
|
||
output "container_registry_name" { | ||
value = azurecaf_name.container_registry.result | ||
value = azurerm_container_registry.container_registry.name | ||
description = "The Docker Container Registry name generated by the Azure Cloud Adoption Framework." | ||
} | ||
|
||
output "container_apps_identity" { | ||
value = azurerm_user_assigned_identity.msi_container_app.id | ||
description = "The Managed Identity assigned to container apps" | ||
} | ||
|
||
|
||
output "database_login_name" { | ||
value = local.database_login_name | ||
} | ||
|
||
output "container_environment_name" { | ||
value = azurerm_container_app_environment.application.name | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,23 @@ | ||
output "database_url" { | ||
value = "${azurerm_mysql_flexible_server.database.name}.mysql.database.azure.com:3306/${azurerm_mysql_flexible_database.database.name}" | ||
description = "The MySQL server URL." | ||
output "database_fqdn" { | ||
value = azurerm_mysql_flexible_server.database.fqdn | ||
description = "The MySQL server FQDN." | ||
} | ||
|
||
output "database_server_name" { | ||
value = azurerm_mysql_flexible_server.database.name | ||
description = "The MySQL server name." | ||
} | ||
|
||
output "database_name" { | ||
value = azurerm_mysql_flexible_database.database.name | ||
description = "The MySQL database name." | ||
} | ||
|
||
output "database_username" { | ||
value = azurerm_mysql_flexible_server_active_directory_administrator.aad_admin.login | ||
description = "The MySQL server user name." | ||
} | ||
|
||
output "database_dotnet_connection_string" { | ||
value= "Server=${azurerm_mysql_flexible_server.database.fqdn};Database=${azurerm_mysql_flexible_database.database.name};SslMode=Required" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.