Skip to content

Commit 1a74eb3

Browse files
authored
4356 Fix & polished the QAS enabled Mission (#316)
1 parent 5b59a24 commit 1a74eb3

File tree

9 files changed

+474
-280
lines changed

9 files changed

+474
-280
lines changed

released/discovery_center/mission_4356/step1/locals.tf

Lines changed: 0 additions & 4 deletions
This file was deleted.

released/discovery_center/mission_4356/step1/main.tf

Lines changed: 179 additions & 80 deletions
Large diffs are not rendered by default.

released/discovery_center/mission_4356/step1/outputs.tf

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
output "globalaccount" {
2-
value = var.globalaccount
3-
description = "The globalaccount subdomain."
1+
output "subaccount_id" {
2+
value = data.btp_subaccount.dc_mission.id
3+
description = "The ID of the subaccount."
44
}
55

6-
output "cli_server_url" {
7-
value = var.cli_server_url
8-
description = "The BTP CLI server URL."
6+
output "integrationsuite_subscription_url" {
7+
value = btp_subaccount_subscription.integrationsuite.subscription_url
8+
description = "SAP Integration Suite subscription URL."
99
}
1010

11-
output "subaccount_id" {
12-
value = data.btp_subaccount.dc_mission.id
13-
description = "The ID of the subaccount."
11+
output "custom_idp" {
12+
value = var.custom_idp
13+
description = "The custom identity provider."
1414
}
1515

1616
output "cf_api_url" {
1717
value = jsondecode(btp_subaccount_environment_instance.cloudfoundry.labels)["API Endpoint"]
18-
description = "The Cloudfoundry API endpoint."
18+
description = "The Cloudfoundry API Url."
1919
}
2020

2121
output "cf_landscape_label" {
Lines changed: 24 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,34 @@
11
# ------------------------------------------------------------------------------------------------------
22
# Provider configuration
33
# ------------------------------------------------------------------------------------------------------
4-
# Your global account subdomain
5-
globalaccount = "yourglobalaccount"
4+
custom_idp = "<<tenant-id>>.accounts.ondemand.com"
5+
6+
# ------------------------------------------------------------------------------------------------------
7+
# Account settings
8+
# ------------------------------------------------------------------------------------------------------
9+
globalaccount = "<your-global-account-subdomain>"
610
region = "us10"
711
subaccount_name = "SAP Discovery Center Mission 4356"
812

913
# ------------------------------------------------------------------------------------------------------
10-
# Project specific configuration (please adapt!)
14+
# Use case specific configuration
1115
# ------------------------------------------------------------------------------------------------------
16+
subaccount_admins = ["[email protected]", "[email protected]"]
17+
subaccount_service_admins = ["[email protected]", "[email protected]"]
18+
19+
integration_provisioners = ["[email protected]", "[email protected]"]
20+
sapappstudio_admins = ["[email protected]", "[email protected]"]
21+
sapappstudio_developers = ["[email protected]", "[email protected]"]
1222

13-
subaccount_admins = ["[email protected]"]
14-
subaccount_service_admins = ["[email protected]"]
15-
cf_org_admins = ["[email protected]"]
16-
cf_org_users = ["[email protected]"]
17-
cf_space_managers = ["[email protected]", "[email protected]"]
18-
cf_space_developers = ["[email protected]", "[email protected]"]
23+
cloud_connector_admins = ["[email protected]", "[email protected]"]
24+
connectivity_destination_admins = ["[email protected]", "[email protected]"]
1925

20-
custom_idp = "sap.ids"
26+
cf_org_admins = ["[email protected]", "[email protected]"]
27+
28+
cf_space_managers = ["[email protected]", "[email protected]"]
29+
cf_space_developers = ["[email protected]", "[email protected]"]
30+
31+
# ------------------------------------------------------------------------------------------------------
32+
# Create tfvars file for the step 2
33+
# ------------------------------------------------------------------------------------------------------
34+
create_tfvars_file_for_step2 = true

released/discovery_center/mission_4356/step1/variables.tf

Lines changed: 115 additions & 99 deletions
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,63 @@
1-
######################################################################
2-
# Customer account setup
3-
######################################################################
4-
# subaccount
1+
# ------------------------------------------------------------------------------------------------------
2+
# Account variables
3+
# ------------------------------------------------------------------------------------------------------
54
variable "globalaccount" {
65
type = string
7-
description = "The globalaccount subdomain."
8-
default = "yourglobalaccount"
6+
description = "The globalaccount subdomain where the sub account shall be created."
97
}
108

11-
variable "subaccount_id" {
9+
variable "cli_server_url" {
1210
type = string
13-
description = "The subaccount ID."
11+
description = "The BTP CLI server URL."
12+
default = "https://cli.btp.cloud.sap"
13+
}
14+
15+
variable "custom_idp" {
16+
type = string
17+
description = "The custom identity provider for the subaccount."
1418
default = ""
1519
}
1620

17-
# subaccount
21+
variable "custom_idp_apps_origin_key" {
22+
type = string
23+
description = "The custom identity provider for the subaccount."
24+
default = "sap.custom"
25+
}
26+
27+
variable "region" {
28+
type = string
29+
description = "The region where the subaccount shall be created in."
30+
default = "us10"
31+
}
32+
1833
variable "subaccount_name" {
1934
type = string
2035
description = "The subaccount name."
21-
default = "UC - Deliver Connected Experiences with a single view of Material Availability"
36+
default = "My SAP Build Code subaccount."
2237
}
2338

24-
variable "custom_idp" {
39+
variable "subaccount_id" {
2540
type = string
26-
description = "Defines the custom IdP"
41+
description = "The subaccount ID."
2742
default = ""
2843
}
2944

45+
# ------------------------------------------------------------------------------------------------------
46+
# cf related variables
47+
# ------------------------------------------------------------------------------------------------------
3048
variable "origin" {
3149
type = string
32-
description = "Defines the origin of the identity provider"
50+
description = "Defines the origin key of the identity provider"
3351
default = "sap.ids"
34-
# The value for the origin can be defined
52+
# The value for the origin_key can be defined
3553
# but are normally set to "sap.ids", "sap.default" or "sap.custom"
3654
}
3755

38-
variable "cf_space_name" {
56+
variable "origin_key" {
3957
type = string
40-
description = "Name of the Cloud Foundry space."
41-
default = "dev"
42-
43-
validation {
44-
condition = can(regex("^.{1,255}$", var.cf_space_name))
45-
error_message = "The Cloud Foundry space name must not be emtpy and not exceed 255 characters."
46-
}
58+
description = "Defines the origin key of the identity provider"
59+
default = ""
60+
# The value for the origin_key can be defined, set to "sap.ids", "sap.default" or "sap.custom"
4761
}
4862

4963
variable "cf_landscape_label" {
@@ -55,141 +69,140 @@ variable "cf_landscape_label" {
5569
variable "cf_org_name" {
5670
type = string
5771
description = "Name of the Cloud Foundry org."
58-
default = "mission-4356"
72+
default = "mission-4441-sap-build-code"
5973

6074
validation {
6175
condition = can(regex("^.{1,255}$", var.cf_org_name))
6276
error_message = "The Cloud Foundry org name must not be emtpy and not exceed 255 characters."
6377
}
6478
}
65-
# Region
66-
variable "region" {
79+
80+
variable "cf_space_name" {
6781
type = string
68-
description = "The region where the project account shall be created in."
69-
default = "us10"
82+
description = "Name of the Cloud Foundry space."
83+
default = "dev"
84+
85+
validation {
86+
condition = can(regex("^.{1,255}$", var.cf_space_name))
87+
error_message = "The Cloud Foundry space name must not be emtpy and not exceed 255 characters."
88+
}
7089
}
7190

91+
/*
7292
# hana password
7393
variable "hana_cloud_system_password" {
7494
type = string
7595
description = "The system password for the hana_cloud service instance."
7696
default = "Abcd1234"
7797
}
98+
*/
7899

79-
# CLI server
80-
variable "cli_server_url" {
100+
# ------------------------------------------------------------------------------------------------------
101+
# services plans
102+
# ------------------------------------------------------------------------------------------------------
103+
variable "service_plan__cloudfoundry" {
81104
type = string
82-
description = "The BTP CLI server URL."
83-
default = "https://cpcli.cf.eu10.hana.ondemand.com"
105+
description = "The plan for service 'Destination Service' with technical name 'destination'"
106+
default = "standard"
107+
validation {
108+
condition = contains(["standard"], var.service_plan__cloudfoundry)
109+
error_message = "Invalid value for service_plan__cloudfoundry. Only 'standard' is allowed."
110+
}
84111
}
85112

86-
# subaccount variables
87-
variable "subaccount_admins" {
88-
type = list(string)
89-
description = "Defines the colleagues who are added to each subaccount as subaccount administrators."
90-
113+
variable "service_plan__connectivity" {
114+
type = string
115+
description = "The plan for service 'Connectivity Service' with technical name 'connectivity'"
116+
default = "lite"
91117
}
92118

93-
variable "subaccount_service_admins" {
94-
type = list(string)
95-
description = "Defines the colleagues who are added to each subaccount as subaccount service administrators."
96-
119+
variable "service_plan__destination" {
120+
type = string
121+
description = "The plan for service 'Destination Service' with technical name 'destination'"
122+
default = "lite"
123+
}
124+
125+
variable "service_plan__html5_apps_repo" {
126+
type = string
127+
description = "The plan for service 'HTML5 Application Repository Service' with technical name 'html5-apps-repo'"
128+
default = "app-host"
97129
}
98130

99-
variable "service_plan__sap_integration_suite" {
131+
variable "service_plan__xsuaa" {
132+
type = string
133+
description = "The plan for service 'Authorization and Trust Management Service' with technical name 'xsuaa'"
134+
default = "application"
135+
}
136+
137+
# ------------------------------------------------------------------------------------------------------
138+
# app subscription plans
139+
# ------------------------------------------------------------------------------------------------------
140+
variable "service_plan__integrationsuite" {
100141
type = string
101-
description = "The plan for SAP Integration Suite"
142+
description = "The plan for service 'Integration Suite' with technical name 'integrationsuite'"
102143
default = "enterprise_agreement"
103144
validation {
104-
condition = contains(["free", "enterprise_agreement"], var.service_plan__sap_integration_suite)
105-
error_message = "Invalid value for service_plan__sap_integration_suite. Only 'free' and 'enterprise_agreement' are allowed."
145+
condition = contains(["enterprise_agreement", "free"], var.service_plan__integrationsuite)
146+
error_message = "Invalid value for service_plan__integrationsuite. Only 'enterprise_agreement' and 'free' are allowed."
106147
}
107148
}
108149

109-
variable "service_plan__sap_business_app_studio" {
150+
variable "service_plan__sapappstudio" {
110151
type = string
111-
description = "The plan for SAP Business Application Studio"
152+
description = "The plan for service 'SAP Business Application Studio' with technical name 'sapappstudio'"
112153
default = "standard-edition"
113154
validation {
114-
condition = contains(["standard-edition"], var.service_plan__sap_business_app_studio)
115-
error_message = "Invalid value for service_plan__sap_business_app_studio. Only 'standard-edition' is allowed."
155+
condition = contains(["standard-edition"], var.service_plan__sapappstudio)
156+
error_message = "Invalid value for service_plan__sapappstudio. Only 'standard-edition' is allowed."
116157
}
117158
}
118159

119160
# ------------------------------------------------------------------------------------------------------
120-
# Entitlements
161+
# User lists
121162
# ------------------------------------------------------------------------------------------------------
122-
variable "entitlements" {
123-
type = list(object({
124-
service_name = string
125-
plan_name = string
126-
type = string
127-
}))
128-
description = "The list of entitlements that shall be added to the subaccount."
129-
default = [
130-
{
131-
service_name = "connectivity"
132-
plan_name = "lite",
133-
type = "service"
134-
},
135-
{
136-
service_name = "destination"
137-
plan_name = "lite",
138-
type = "service"
139-
},
140-
{
141-
service_name = "html5-apps-repo"
142-
plan_name = "app-host",
143-
type = "service"
144-
},
145-
{
146-
service_name = "xsuaa"
147-
plan_name = "application",
148-
type = "service"
149-
}
150-
]
151-
}
152-
153-
variable "appstudio_developers" {
163+
variable "subaccount_admins" {
154164
type = list(string)
155-
description = "Business Application Studio Developer"
156-
165+
description = "Defines the colleagues who are added to subaccount as administrator"
157166
}
158167

159-
variable "appstudio_admins" {
168+
variable "subaccount_service_admins" {
160169
type = list(string)
161-
description = "Business Application Studio Administrator"
162-
170+
description = "Defines the colleagues who are added to subaccount as service administrator"
163171
}
164172

165-
variable "cloudconnector_admins" {
173+
variable "integration_provisioners" {
166174
type = list(string)
167-
description = "Cloud Connector Administrator"
168-
175+
description = "Integration Provisioner"
169176
}
170177

171-
variable "conn_dest_admins" {
178+
variable "sapappstudio_admins" {
172179
type = list(string)
173-
description = "Connectivity and Destination Administrator"
174-
180+
description = "Defines the colleagues who are administrators for SAP Business Application Studio."
175181
}
176182

177-
variable "int_provisioners" {
183+
variable "sapappstudio_developers" {
178184
type = list(string)
179-
description = "Integration Provisioner"
180-
185+
description = "Defines the colleagues who are developers for SAP Business Application Studio."
181186
}
182187

188+
variable "cloud_connector_admins" {
189+
type = list(string)
190+
description = "Defines the colleagues who are administrators for Cloud Connector"
191+
}
183192

184-
variable "cf_org_users" {
193+
variable "connectivity_destination_admins" {
185194
type = list(string)
186-
description = "CF Org Users"
187-
195+
description = "Defines the colleagues who are administrators for Connectivity and Destinations"
188196
}
189197

190198
variable "cf_org_admins" {
191199
type = list(string)
192-
description = "List of users to set as Cloudfoundry org administrators."
200+
description = "Defines the colleagues who are added to a Cloudfoundry as org administrators."
201+
}
202+
203+
variable "cf_org_users" {
204+
type = list(string)
205+
description = "Defines the colleagues who are added to a Cloudfoundry as org users."
193206
}
194207

195208
variable "cf_space_managers" {
@@ -202,6 +215,9 @@ variable "cf_space_developers" {
202215
description = "Defines the colleagues who are added to a CF space as space developer."
203216
}
204217

218+
# ------------------------------------------------------------------------------------------------------
219+
# Switch for creating tfvars for step 2
220+
# ------------------------------------------------------------------------------------------------------
205221
variable "create_tfvars_file_for_step2" {
206222
type = bool
207223
description = "Switch to enable the creation of the tfvars file for step 2."

0 commit comments

Comments
 (0)