Skip to content

Commit bbcfdc3

Browse files
authored
Merge pull request #6 from data-platform-hq/dashboard_and_workbook_support
fix: dashboard and workbook support
2 parents 2facaa6 + ce214ac commit bbcfdc3

File tree

4 files changed

+48
-0
lines changed

4 files changed

+48
-0
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ No resources.
3030
|------|-------------|------|---------|:--------:|
3131
| <a name="input_automation_accounts"></a> [automation\_accounts](#input\_automation\_accounts) | Set of unique strings to create Automation Accounts full names | `set(string)` | `[]` | no |
3232
| <a name="input_container_instances"></a> [container\_instances](#input\_container\_instances) | Set of unique strings to create Container Instances full names | `set(string)` | `[]` | no |
33+
| <a name="input_dashboards"></a> [dashboards](#input\_dashboards) | Set of unique strings to create Dashboards full names | `set(string)` | `[]` | no |
3334
| <a name="input_data_factories"></a> [data\_factories](#input\_data\_factories) | Set of unique strings to create Data Factories full names | `set(string)` | `[]` | no |
3435
| <a name="input_databricks_workspaces"></a> [databricks\_workspaces](#input\_databricks\_workspaces) | Set of unique strings to create Databricks Workspaces full names | `set(string)` | `[]` | no |
3536
| <a name="input_environment"></a> [environment](#input\_environment) | Environment/Subscription name | `string` | n/a | yes |
@@ -54,6 +55,7 @@ No resources.
5455
| <a name="input_storage_accounts"></a> [storage\_accounts](#input\_storage\_accounts) | Set of unique strings to create Storage Accounts full names | `set(string)` | `[]` | no |
5556
| <a name="input_subnets"></a> [subnets](#input\_subnets) | Set of unique strings to create Subnets full names | `set(string)` | `[]` | no |
5657
| <a name="input_virtual_networks"></a> [virtual\_networks](#input\_virtual\_networks) | Set of unique strings to create Virtual Network full names | `set(string)` | `[]` | no |
58+
| <a name="input_workbooks"></a> [workbooks](#input\_workbooks) | Set of unique strings to create Workbooks full names | `set(string)` | `[]` | no |
5759

5860
## Outputs
5961

@@ -63,6 +65,8 @@ No resources.
6365
| <a name="output_automation_accounts"></a> [automation\_accounts](#output\_automation\_accounts) | Built name of multiple Automation Accounts with unique particle |
6466
| <a name="output_container_instance"></a> [container\_instance](#output\_container\_instance) | Built name of single Container Instance |
6567
| <a name="output_container_instances"></a> [container\_instances](#output\_container\_instances) | Built name of multiple Container Instances with unique particle |
68+
| <a name="output_dashboard"></a> [dashboard](#output\_dashboard) | Built name of single Dashboard |
69+
| <a name="output_dashboards"></a> [dashboards](#output\_dashboards) | Built name of multiple Dashboards with unique particle |
6670
| <a name="output_data_factories"></a> [data\_factories](#output\_data\_factories) | Built name of multiple Data Factories with unique particle |
6771
| <a name="output_data_factory"></a> [data\_factory](#output\_data\_factory) | Built name of single Data Factory |
6872
| <a name="output_databricks_workspace"></a> [databricks\_workspace](#output\_databricks\_workspace) | Built name of single Databricks Workspace |
@@ -103,6 +107,8 @@ No resources.
103107
| <a name="output_subnets"></a> [subnets](#output\_subnets) | Built name of multiple Subnets with unique particle |
104108
| <a name="output_virtual_network"></a> [virtual\_network](#output\_virtual\_network) | Built name of single Virtual Network |
105109
| <a name="output_virtual_networks"></a> [virtual\_networks](#output\_virtual\_networks) | Built name of multiple Virtual Networks with unique particle |
110+
| <a name="output_workbook"></a> [workbook](#output\_workbook) | Built name of single Workbook |
111+
| <a name="output_workbooks"></a> [workbooks](#output\_workbooks) | Built name of multiple Workbooks with unique particle |
106112
<!-- END_TF_DOCS -->
107113

108114
## License

main.tf

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,14 @@ locals {
8686
# Purview
8787
purview = substr(join("-", compact(["pvw", var.project, var.environment, var.location, var.instance_number])), 0, 63)
8888
purviews = { for item in var.purviews : item => substr(join("-", compact(["pvw", var.project, item, var.environment, var.location, var.instance_number])), 0, 63) }
89+
90+
# Dashboard
91+
dashboard = substr(join("-", compact(["dsb", var.project, var.environment, var.location, var.instance_number])), 0, 63)
92+
dashboards = { for item in var.dashboards : item => substr(join("-", compact(["dsb", var.project, item, var.environment, var.location, var.instance_number])), 0, 63) }
93+
94+
# Dashboard
95+
workbook = substr(join("-", compact(["wbk", var.project, var.environment, var.location, var.instance_number])), 0, 63)
96+
workbooks = { for item in var.workbooks : item => substr(join("-", compact(["wbk", var.project, item, var.environment, var.location, var.instance_number])), 0, 63) }
8997
}
9098

9199
locals {

outputs.tf

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,3 +239,25 @@ output "purviews" {
239239
description = "Built name of multiple Purviews with unique particle"
240240
value = local.purviews
241241
}
242+
243+
# Dashboard
244+
output "dashboard" {
245+
description = "Built name of single Dashboard"
246+
value = local.dashboard
247+
}
248+
249+
output "dashboards" {
250+
description = "Built name of multiple Dashboards with unique particle"
251+
value = local.dashboards
252+
}
253+
254+
# Workbook
255+
output "workbook" {
256+
description = "Built name of single Workbook"
257+
value = local.workbook
258+
}
259+
260+
output "workbooks" {
261+
description = "Built name of multiple Workbooks with unique particle"
262+
value = local.workbooks
263+
}

variables.tf

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,3 +150,15 @@ variable "purviews" {
150150
description = "Set of unique strings to create Purviews full names"
151151
default = []
152152
}
153+
154+
variable "dashboards" {
155+
type = set(string)
156+
description = "Set of unique strings to create Dashboards full names"
157+
default = []
158+
}
159+
160+
variable "workbooks" {
161+
type = set(string)
162+
description = "Set of unique strings to create Workbooks full names"
163+
default = []
164+
}

0 commit comments

Comments
 (0)