You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- You have an account on SAP BTP. You can check out steps 1-7 of the tutorial on how to [Get an Account on SAP BTP to Try Out Free Tier Service Plans](btp-free-tier-account) (we will automate the rest in this tutorial here).
16
+
- You have the Cloud Foundry CLI, as described in [Installing the cf CLI](https://docs.cloudfoundry.org/cf-cli/install-go-cli.html).
17
+
- You have a UNIX-like environment.
18
+
19
+
## Details
20
+
21
+
### You will learn
22
+
- How to use a script to automate account admin processes
23
+
10
24
---
11
25
12
26
With the introduction of cloud management tools feature set B to SAP BTP, the stars of the show are without a doubt the new REST APIs and command line. With these features, you now have many more options to automate your account administrative flows in SAP BTP.
@@ -38,7 +52,7 @@ For this example, you can download an automation script that we've prepared in a
38
52
39
53
The script will do the following:
40
54
41
-
1. Log in to your global account on SAP BTP.
55
+
1. Log in to your global account on SAP BTP.
42
56
43
57
2. Create a new directory in your account model.
44
58
@@ -52,16 +66,10 @@ The script will do the following:
52
66
53
67
7. Create a space in the Cloud Foundry org of one of the subaccounts.
54
68
55
-
8. Create an instance of the SAP HANA Cloud (`hana`) service in the space.
69
+
8. Create an instance of the SAP HANA Cloud (`hana-free`) service in the space.
56
70
57
71
Through this tutorial, we hope we can help you to unleash the power of CLI script-based automation for your account admin processes on SAP BTP.
58
72
59
-
## Prerequisites
60
-
- You have a trial account on SAP BTP. For a trial account, see [Get a Free Account on SAP BTP Trail](hcp-create-trial-account).
61
-
- You have the Cloud Foundry CLI, as described in [Installing the cf CLI](https://docs.cloudfoundry.org/cf-cli/install-go-cli.html).
62
-
- You have a UNIX-like environment.
63
-
64
-
65
73
---
66
74
67
75
[ACCORDION-BEGIN [Step 1: ](Download and install the client)]
@@ -78,13 +86,13 @@ Download the automation script file from GitHub: <https://github.com/SAP-samples
78
86
79
87
80
88
[ACCORDION-BEGIN [Step 3: ](Change the declarations)]
81
-
In this step, you need to open the script file in your favorite text editor and enter the values in each placeholder according to your trial account and the names and custom properties of the directories and subaccounts that you want to create.
89
+
In this step, you need to open the script file in your favorite text editor and enter the values in each placeholder according to your account and the names and custom properties of the directories and subaccounts that you want to create.
82
90
83
91
These lines declare global variables that will be used in the script.
84
92
85
93
```Bash
86
-
declare region="<enter your trial region, e.g., eu10, us10, ap21>"
87
-
declare global_account_subdomain="<enter your trial global account subdomain, see below where it is located>"
94
+
declare region="<enter your region, e.g., eu10, us10, ap21>"
95
+
declare global_account_subdomain="<enter your global account subdomain, see below where it is located>"
88
96
declare directory_name="<enter a name for the directory of the new project, e.g., Project X>"
89
97
declare directory_description="<enter a description for the directory of the new project, e.g., Directory for project X of partner Y>"
90
98
declare contact_person="<enter the email address of your partner company´s contact person>"
@@ -149,7 +157,7 @@ login_btp() {
149
157
>Two-factor authentication is only relevant for Password grant type authorization.
150
158
151
159
152
-
The following function creates a new directory in your trial global account, with the name and description that you provided in Step 3.
160
+
The following function creates a new directory in your global account, with the name and description that you provided in Step 3.
153
161
154
162
In addition, it sets the directory features, admin, and custom properties.
155
163
There are two custom properties here:
@@ -187,8 +195,8 @@ The following function assigns the service and plan it receives as input, as an
187
195
188
196
In the `main` function of the script, we'll use the following function to assign two service entitlements to your directory:
189
197
190
-
- SAP Alert Notification service (`standard`)
191
-
- SAP HANA Cloud (`hana`)
198
+
- SAP Alert Notification service (`free`)
199
+
- SAP HANA Cloud (`hana-free`)
192
200
193
201
Since `distribute` and `auto-assign` are specified, every subaccount that is created in or moved to the directory will automatically be assigned these entitlements as well (as long as the directory has remaining quota for these services).
@@ -413,7 +421,7 @@ Open your terminal in the location in which you saved it, then execute i
413
421
414
422
[ACCORDION-BEGIN [Step 6: ](See the results)]
415
423
416
-
Once the script has finished executing, open your SAP BTP Trial cockpit and locate the new directory, subaccounts, entitlements, org, space, and the instance of the SAP HANA Cloud service.
424
+
Once the script has finished executing, open your SAP BTP cockpit and locate the new directory, subaccounts, entitlements, org, space, and the instance of the SAP HANA Cloud service.
0 commit comments