|
2 | 2 |
|
3 | 3 | WebLogic Server supports two types of clustering configurations, configured and dynamic. Configured clusters are created by manually configuring each individual Managed Server instance. In dynamic clusters, the Managed Server configurations are generated from a single, shared template. With dynamic clusters, when additional server capacity is needed, new server instances can be added to the cluster without having to manually configure them individually. Also, unlike configured clusters, scaling up of dynamic clusters is not restricted to the set of servers defined in the cluster but can be increased based on runtime demands. For more information on how to create, configure, and use dynamic clusters in WebLogic Server, see [Dynamic Clusters](https://docs.oracle.com/middleware/1221/wls/CLUST/dynamic_clusters.htm#CLUST678).
|
4 | 4 |
|
5 |
| -The following blogs provide more in-depth information on support for scaling WebLogic clusters in Kubernetes: |
6 |
| -* [Automatic Scaling of WebLogic Clusters on Kubernetes](https://blogs.oracle.com/weblogicserver/automatic-scaling-of-weblogic-clusters-on-kubernetes-v2) |
7 |
| -* [WebLogic Dynamic Clusters on Kubernetes](https://blogs.oracle.com/weblogicserver/weblogic-dynamic-clusters-on-kubernetes) |
| 5 | +The following blog provides more in-depth information on support for scaling WebLogic clusters in Kubernetes, [WebLogic Dynamic Clusters on Kubernetes.](https://blogs.oracle.com/weblogicserver/weblogic-dynamic-clusters-on-kubernetes) |
8 | 6 |
|
9 | 7 | The operator provides several ways to initiate scaling of WebLogic clusters, including:
|
10 | 8 |
|
@@ -112,25 +110,25 @@ are used to enable and configure the external REST endpoint:
|
112 | 110 | # interface. They are specified by the 'externalOperatorCert' and
|
113 | 111 | # 'eternalOperatorKey' properties.
|
114 | 112 | externalRestOption: NONE
|
115 |
| - |
| 113 | +
|
116 | 114 | # The node port that should be allocated for the external operator REST https interface.
|
117 | 115 | # This parameter is required if 'externalRestOption' is not 'NONE'.
|
118 | 116 | # Otherwise, it is ignored.
|
119 | 117 | externalRestHttpsPort: 31001
|
120 |
| - |
| 118 | +
|
121 | 119 | # The subject alternative names to put into the generated self-signed certificate
|
122 | 120 | # for the external WebLogic Operator REST https interface, for example:
|
123 | 121 | # DNS:myhost,DNS:localhost,IP:127.0.0.1
|
124 | 122 | # This parameter is required if 'externalRestOption' is 'SELF_SIGNED_CERT'.
|
125 | 123 | # Otherwise, it is ignored.
|
126 | 124 | externalSans:
|
127 |
| - |
| 125 | +
|
128 | 126 | # The customer supplied certificate to use for the external operator REST
|
129 | 127 | # https interface. The value must be a string containing a base64 encoded PEM certificate.
|
130 | 128 | # This parameter is required if 'externalRestOption' is 'CUSTOM_CERT'.
|
131 | 129 | # Otherwise, it is ignored.
|
132 | 130 | externalOperatorCert:
|
133 |
| - |
| 131 | +
|
134 | 132 | # The customer supplied private key to use for the external operator REST
|
135 | 133 | # https interface. The value must be a string containing a base64 encoded PEM key.
|
136 | 134 | # This parameter is required if 'externalRestOption' is 'CUSTOM_CERT'.
|
@@ -184,13 +182,13 @@ see [Configuring Policies and Actions](https://docs.oracle.com/middleware/1221/w
|
184 | 182 | ```
|
185 | 183 | ```
|
186 | 184 | Name: `weblogic-operator-cm`
|
187 |
| - |
| 185 | + |
188 | 186 | Namespace: `weblogic-operator`
|
189 |
| - |
| 187 | + |
190 | 188 | Labels: `weblogic.operatorName=weblogic-operator`
|
191 |
| - |
| 189 | + |
192 | 190 | Annotations: `kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"v1","data":{"externalOperatorCert":"","internalOperatorCert":"LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0t...`
|
193 |
| - |
| 191 | + |
194 | 192 | Data
|
195 | 193 |
|
196 | 194 | ====
|
@@ -231,10 +229,7 @@ see [Configuring Policies and Actions](https://docs.oracle.com/middleware/1221/w
|
231 | 229 | * REST
|
232 | 230 | * JMX application
|
233 | 231 |
|
234 |
| -A more in-depth description and example on using WLDF's Policies and Actions component for initiating scaling requests through the operator's REST endpoint can be found in the blogs: |
235 |
| -* [Automatic Scaling of WebLogic Clusters on Kubernetes](https://blogs.oracle.com/weblogicserver/automatic-scaling-of-weblogic-clusters-on-kubernetes-v2) |
236 |
| -* [WebLogic Dynamic Clusters on Kubernetes](https://blogs.oracle.com/weblogicserver/weblogic-dynamic-clusters-on-kubernetes) |
237 |
| - |
| 232 | +A more in-depth description and example on using WLDF's Policies and Actions component for initiating scaling requests through the operator's REST endpoint can be found in the blog [WebLogic Dynamic Clusters on Kubernetes](https://blogs.oracle.com/weblogicserver/weblogic-dynamic-clusters-on-kubernetes). |
238 | 233 |
|
239 | 234 |
|
240 | 235 | ### Create cluster role bindings to allow a namespace user to query WLS Kubernetes cluster information
|
@@ -340,31 +335,31 @@ size=3 #New cluster size
|
340 | 335 | domdir=${PWD}
|
341 | 336 | ns=weblogic-operator # Operator NameSpace
|
342 | 337 | domainuid=domain1
|
343 |
| - |
| 338 | +
|
344 | 339 | # Retrieve service account name for given namespace
|
345 | 340 | sec=`kubectl get serviceaccount ${ns} -n ${ns} -o jsonpath='{.secrets[0].name}'`
|
346 | 341 | #echo "Secret [${sec}]"
|
347 |
| - |
| 342 | +
|
348 | 343 | # Retrieve base64 encoded secret for the given service account
|
349 | 344 | enc_token=`kubectl get secret ${sec} -n ${ns} -o jsonpath='{.data.token}'`
|
350 | 345 | #echo "enc_token [${enc_token}]"
|
351 |
| - |
| 346 | +
|
352 | 347 | # Decode the base64 encoded token
|
353 | 348 | token=`echo ${enc_token} | base64 --decode`
|
354 | 349 | #echo "token [${token}]"
|
355 |
| - |
| 350 | +
|
356 | 351 | # Retrieve SSL certificate for the external REST endpoint from the generated yaml file for the Operator
|
357 | 352 | operator_cert_data=`kubectl get cm -n ${ns} weblogic-operator-cm -o jsonpath='{.data.externalOperatorCert}'`
|
358 | 353 | #echo "operator_cert_data [${operator_cert_data}]"
|
359 |
| - |
| 354 | +
|
360 | 355 | # clean up any temporary files
|
361 | 356 | rm -rf operator.rest.response.body operator.rest.stderr operator.cert.pem
|
362 |
| - |
| 357 | +
|
363 | 358 | # Decode and store the encoded SSL certificate into a pem file
|
364 | 359 | echo ${operator_cert_data} | base64 --decode > operator.cert.pem
|
365 |
| - |
| 360 | +
|
366 | 361 | echo "Rest EndPoint url https://${ophost}:${opport}/operator/v1/domains/${domainuid}/clusters/${cluster}/scale"
|
367 |
| - |
| 362 | +
|
368 | 363 | # Issue 'curl' request to external REST endpoint
|
369 | 364 | curl --noproxy '*' -v --cacert operator.cert.pem \
|
370 | 365 | -H "Authorization: Bearer ${token}" \
|
|
0 commit comments