generated from nhs-england-tools/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 2
DTOSS-11637: Add a shared dashboard module #261
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,4 @@ | ||
| # app-insights | ||
|
|
||
| ## Terraform documentation | ||
| For the list of inputs, outputs, resources... check the [terraform module documentation](tfdocs.md). |
This file contains hidden or 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 @@ | ||
| resource "azurerm_portal_dashboard" "dashboard" { | ||
|
|
||
| name = var.name | ||
| location = var.location | ||
| resource_group_name = var.resource_group_name | ||
| tags = var.tags | ||
|
|
||
| dashboard_properties = var.dashboard_properties | ||
| } |
This file contains hidden or 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,50 @@ | ||
| # Module documentation | ||
|
|
||
| ## Required Inputs | ||
|
|
||
| The following input variables are required: | ||
|
|
||
| ### <a name="input_location"></a> [location](#input\_location) | ||
|
|
||
| Description: The location/region where the dashboard is created. | ||
|
|
||
| Type: `string` | ||
|
|
||
| ### <a name="input_name"></a> [name](#input\_name) | ||
|
|
||
| Description: Is the dashboard workspace name. | ||
|
|
||
| Type: `string` | ||
|
|
||
| ### <a name="input_resource_group_name"></a> [resource\_group\_name](#input\_resource\_group\_name) | ||
|
|
||
| Description: The name of the resource group in which the Dashboard is created. Changing this forces a new resource to be created. | ||
|
|
||
| Type: `string` | ||
|
|
||
| ## Optional Inputs | ||
|
|
||
| The following input variables are optional (have default values): | ||
|
|
||
| ### <a name="input_dashboard_properties"></a> [dashboard\_properties](#input\_dashboard\_properties) | ||
|
|
||
| Description: JSON data representing dashboard body. See above for details on how to obtain this from the Portal. | ||
|
|
||
| Type: `string` | ||
|
|
||
| Default: `{}` | ||
|
|
||
| ### <a name="input_tags"></a> [tags](#input\_tags) | ||
|
|
||
| Description: A mapping of tags to assign to the resource. | ||
|
|
||
| Type: `map(string)` | ||
|
|
||
| Default: `{}` | ||
|
|
||
|
|
||
| ## Resources | ||
|
|
||
| The following resources are used by this module: | ||
|
|
||
| - [azurerm_portal_dashboard.dashboard](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/portal_dashboard) (resource) |
This file contains hidden or 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,30 @@ | ||
| variable "location" { | ||
| type = string | ||
| description = "The location/region where the dashboard is created." | ||
| } | ||
|
|
||
| variable "name" { | ||
| description = "Is the dashboard workspace name." | ||
| type = string | ||
| validation { | ||
| condition = can(regex("^[a-zA-Z0-9][a-zA-Z0-9-_]{0,253}[a-zA-Z0-9]$", var.name)) | ||
| error_message = "The Dashboard name must be between 1 and 255 characters, start and end with an alphanumeric character, and can contain alphanumeric characters, hyphens, periods, and underscores (but not at the start or end)." | ||
| } | ||
| } | ||
|
|
||
| variable "resource_group_name" { | ||
| type = string | ||
| description = "The name of the resource group in which the Dashboard is created. Changing this forces a new resource to be created." | ||
| } | ||
|
|
||
| variable "tags" { | ||
| type = map(string) | ||
| default = {} | ||
| description = "A mapping of tags to assign to the resource." | ||
| } | ||
|
|
||
| variable "dashboard_properties" { | ||
| type = string | ||
| default = {} | ||
| description = "JSON data representing dashboard body. See above for details on how to obtain this from the Portal." | ||
| } | ||
This file contains hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.