forked from OfficeDev/microsoft-teams-apps-icebreaker
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmanifest.tf
65 lines (55 loc) · 1.83 KB
/
manifest.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
resource "local_file" "icon_color" {
content_base64 = filebase64(var.icon_color_path)
filename = "${path.module}/tmp/color.png"
}
resource "local_file" "icon_outline" {
content_base64 = filebase64(var.icon_outline_path)
filename = "${path.module}/tmp/outline.png"
}
resource "local_file" "manifest" {
filename = "${path.module}/tmp/manifest.json"
content = jsonencode({
"$schema" = "https://developer.microsoft.com/en-us/json-schemas/teams/v1.5/MicrosoftTeams.schema.json"
"manifestVersion" = "1.5"
"version" = var.app_version
"id" = azuread_application.icebreaker.application_id
"packageName" = "de.whitetom.icebreaker${var.name}"
"developer" = {
"name" = var.companyName
"websiteUrl" = var.websiteUrl
"privacyUrl" = var.privacyUrl
"termsOfUseUrl" = var.termsOfUseUrl
}
"localizationInfo" = {
"defaultLanguageTag" = "de"
}
"icons" = {
"color" = "color.png"
"outline" = "outline.png"
}
"name" = {
"short" = var.name
}
"description" = {
"short" = var.description_short
"full" = var.description_long
}
"accentColor" = "#1037A6"
"bots" = [{
"botId" = azuread_application.icebreaker.application_id
"scopes" = ["personal", "team"]
"supportsFiles" = false
"isNotificationOnly" = true
}]
"permissions" = ["identity", "messageTeamMembers"]
"validDomains" = [jsondecode(azurerm_resource_group_template_deployment.icebreaker.output_content).appDomain.value]
})
}
data "archive_file" "app_package" {
type = "zip"
output_path = "${path.module}/manifest.zip"
source_dir = "${path.module}/tmp"
depends_on = [
local_file.icon_outline, local_file.icon_color, local_file.manifest
]
}