Skip to content

Commit 4241e43

Browse files
committed
Merge remote-tracking branch 'origin/2.0-rc2' into rmarano
2 parents 96a859b + ab7fa7b commit 4241e43

File tree

9 files changed

+251
-170
lines changed

9 files changed

+251
-170
lines changed

kubernetes/samples/scripts/common/domain-template.yaml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,9 @@ spec:
3030
name: %WEBLOGIC_CREDENTIALS_SECRET_NAME%
3131
# Whether to include the server out file into the pod's stdout, default is true
3232
includeServerOutInPodLog: %INCLUDE_SERVER_OUT_IN_POD_LOG%
33-
# Whether to enable log home
33+
# Whether to enable log home
3434
%LOG_HOME_ON_PV_PREFIX%logHomeEnabled: %LOG_HOME_ENABLED%
35-
# The in-pod name of the directory to store the domain, node manager, server logs, and server .out
36-
# files in.
37-
# If not specified or empty, domain log file, server logs, server out, and node manager log files
38-
# will be stored in the default logHome location of /shared/logs/<domainUID>/.
35+
# The in-pod location for domain log, server logs, server out, and node manager log files
3936
%LOG_HOME_ON_PV_PREFIX%logHome: %LOG_HOME%
4037
# serverStartPolicy legal values are "NEVER", "IF_NEEDED", or "ADMIN_ONLY"
4138
# This determines which WebLogic Servers the Operator will start up when it discovers this Domain

kubernetes/samples/scripts/common/validate.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env bash
2-
# Copyright 2018, Oracle Corporation and/or its affiliates. All rights reserved.
2+
# Copyright 2018, 2019, Oracle Corporation and/or its affiliates. All rights reserved.
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55
# Description

kubernetes/samples/scripts/create-weblogic-domain/domain-home-in-image/README.md

Lines changed: 69 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ The following parameters can be provided in the inputs file.
115115
| `initialManagedServerReplicas` | Number of Managed Servers to initially start for the domain. | `2` |
116116
| `javaOptions` | Java options for starting the Administration and Managed Servers. A Java option can have references to one or more of the following pre-defined variables to obtain WebLogic domain information: `$(DOMAIN_NAME)`, `$(DOMAIN_HOME)`, `$(ADMIN_NAME)`, `$(ADMIN_PORT)`, and `$(SERVER_NAME)`. | `-Dweblogic.StdoutDebugEnabled=false` |
117117
| `logHomeOnPV` | Specifies whether the log home is stored on the persistent volume. If set to true, then you must specify the `logHome`, `persistentVolumeClaimName` and `domainPVMountPath` parameters.| `false` |
118-
| `logHome` | The in-pod name of the directory in which to store the domain, Node Manager, server logs, and server .out files. If not specified, the value is derived from the `domainUID` as `/shared/logs/<domainUID>`. This parameter is required if `logHomeOnPV` is true. Otherwise, it is ignored. | `/shared/logs/domain1` |
118+
| `logHome` | The in-pod location for domain log, server logs, server out, and node manager log files. If not specified, the value is derived from the `domainUID` as `/shared/logs/<domainUID>`. This parameter is required if `logHomeOnPV` is true. Otherwise, it is ignored. | `/shared/logs/domain1` |
119119
| `managedServerNameBase` | Base string used to generate Managed Server names. | `managed-server` |
120120
| `managedServerPort` | Port number for each Managed Server. | `8001` |
121121
| `namespace` | Kubernetes namespace in which to create the domain. | `default` |
@@ -141,7 +141,8 @@ Note that the example results below use the `default` Kubernetes namespace. If y
141141
The content of the generated `domain.yaml`:
142142

143143
```
144-
# Copyright 2017, 2018, Oracle Corporation and/or its affiliates. All rights reserved.
144+
# Copyright 2017, 2019, Oracle Corporation and/or its affiliates. All rights reserved.
145+
145146
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
146147
#
147148
# This is an example of how to define a Domain resource.
@@ -160,18 +161,25 @@ spec:
160161
# If the domain home is in the image
161162
domainHomeInImage: true
162163
# The Operator currently does not support other images
163-
image: "domain-home-in-image:latest"
164-
# imagePullPolicy defaults to "Never"
165-
imagePullPolicy: "Never"
164+
image: "domain-home-in-image"
165+
# imagePullPolicy defaults to "Always" if image version is :latest
166+
imagePullPolicy: "IfNotPresent"
167+
# Identify which Secret contains the credentials for pulling an image
168+
#imagePullSecrets:
169+
#- name:
166170
# Identify which Secret contains the WebLogic Admin credentials (note that there is an example of
167171
# how to create that Secret at the end of this file)
168172
webLogicCredentialsSecret:
169173
name: domain1-weblogic-credentials
170174
# Whether to include the server out file into the pod's stdout, default is true
171175
includeServerOutInPodLog: true
176+
# Whether to enable log home
177+
# logHomeEnabled: false
178+
# The in-pod location for domain log, server logs, server out, and node manager log files
179+
# logHome: /shared/logs/domain1
172180
# serverStartPolicy legal values are "NEVER", "IF_NEEDED", or "ADMIN_ONLY"
173181
# This determines which WebLogic Servers the Operator will start up when it discovers this Domain
174-
# - "NEVER" will not start any servers in the domain
182+
# - "NEVER" will not start any server in the domain
175183
# - "ADMIN_ONLY" will start up only the administration server (no managed servers will be started)
176184
# - "IF_NEEDED" will start all non-clustered servers, including the administration server and clustered servers up to the replica count
177185
serverStartPolicy: "IF_NEEDED"
@@ -182,26 +190,34 @@ spec:
182190
value: "-Dweblogic.StdoutDebugEnabled=false"
183191
- name: USER_MEM_ARGS
184192
value: "-Xms64m -Xmx256m "
193+
# volumes:
194+
# - name: weblogic-domain-storage-volume
195+
# persistentVolumeClaim:
196+
# claimName: domain1-weblogic-sample-pvc
197+
# volumeMounts:
198+
# - mountPath: /shared
199+
# name: weblogic-domain-storage-volume
185200
# adminServer is used to configure the desired behavior for starting the administration server.
186201
adminServer:
187-
# serverStartState legal values are "RUNNING" or "ADMIN"
188-
# "RUNNING" means the listed server will be started up to "RUNNING" mode
189-
# "ADMIN" means the listed server will be start up to "ADMIN" mode
202+
# serverStartState legal values are "RUNNING" or "ADMIN"
203+
# "RUNNING" means the listed server will be started up to "RUNNING" mode
204+
# "ADMIN" means the listed server will be start up to "ADMIN" mode
190205
serverStartState: "RUNNING"
206+
# adminService:
207+
# channels:
191208
# The Admin Server's NodePort
192-
# nodePort: 30701
209+
# - channelName: default
210+
# nodePort: 30701
193211
# Uncomment to export the T3Channel as a service
194-
# exportedNetworkAccessPoints:
195-
# T3Channel: {}
196-
# clusters is used to configure the desired behavior for starting member servers of a cluster.
212+
# - channelName: T3Channel
213+
# clusters is used to configure the desired behavior for starting member servers of a cluster.
197214
# If you use this entry, then the rules will be applied to ALL servers that are members of the named clusters.
198215
clusters:
199-
cluster-1:
200-
desiredState: "RUNNING"
201-
replicas: 2
216+
- clusterName: cluster-1
217+
serverStartState: "RUNNING"
218+
replicas: 2
202219
# The number of managed servers to start for unlisted clusters
203220
# replicas: 1
204-
205221
```
206222
###
207223

@@ -223,119 +239,122 @@ Name: domain1
223239
Namespace: default
224240
Labels: weblogic.domainUID=domain1
225241
weblogic.resourceVersion=domain-v2
226-
Annotations: kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"weblogic.oracle/v2","kind":"Domain","metadata":{"annotations":{},"labels":{"weblogic.domainUID":"domain1","weblogic.resourceVersion":"do...
242+
Annotations: <none>
227243
API Version: weblogic.oracle/v2
228244
Kind: Domain
229245
Metadata:
230246
Cluster Name:
231-
Creation Timestamp: 2018-12-17T05:58:12Z
247+
Creation Timestamp: 2019-01-10T14:29:37Z
232248
Generation: 1
233-
Resource Version: 15193
249+
Resource Version: 3698533
234250
Self Link: /apis/weblogic.oracle/v2/namespaces/default/domains/domain1
235-
UID: bce25779-01c0-11e9-baf4-0021f6985fb7
251+
UID: 28655979-14e4-11e9-b751-fa163e855ac8
236252
Spec:
237253
Admin Server:
238-
Exported Network Access Points:
239-
Node Port Annotations:
240-
Node Port Labels:
241254
Server Pod:
255+
Annotations:
242256
Container Security Context:
243257
Env:
258+
Labels:
244259
Liveness Probe:
245260
Node Selector:
246-
Pod Annotations:
247-
Pod Labels:
248261
Pod Security Context:
249262
Readiness Probe:
250263
Resources:
251264
Limits:
252265
Requests:
253-
Service Annotations:
254-
Service Labels:
255266
Volume Mounts:
256267
Volumes:
268+
Server Service:
269+
Annotations:
270+
Labels:
257271
Server Start State: RUNNING
258272
Clusters:
259273
Cluster Name: cluster-1
260-
Replicas: 2
274+
Cluster Service:
275+
Annotations:
276+
Labels:
277+
Replicas: 2
261278
Server Pod:
279+
Annotations:
262280
Container Security Context:
263281
Env:
282+
Labels:
264283
Liveness Probe:
265284
Node Selector:
266-
Pod Annotations:
267-
Pod Labels:
268285
Pod Security Context:
269286
Readiness Probe:
270287
Resources:
271288
Limits:
272289
Requests:
273-
Service Annotations:
274-
Service Labels:
275290
Volume Mounts:
276291
Volumes:
292+
Server Service:
293+
Annotations:
294+
Labels:
277295
Server Start State: RUNNING
278296
Domain Home: /u01/oracle/user_projects/domains/domain1
279297
Domain Home In Image: true
280-
Image: domain-home-in-image:latest
281-
Image Pull Policy: Never
298+
Image: domain-home-in-image
299+
Image Pull Policy: IfNotPresent
282300
Include Server Out In Pod Log: true
283301
Managed Servers:
284302
Server Pod:
303+
Annotations:
285304
Container Security Context:
286305
Env:
287306
Name: JAVA_OPTIONS
288307
Value: -Dweblogic.StdoutDebugEnabled=false
289308
Name: USER_MEM_ARGS
290-
Value: -Xms64m -Xmx256m
309+
Value: -Xms64m -Xmx256m
310+
Labels:
291311
Liveness Probe:
292312
Node Selector:
293-
Pod Annotations:
294-
Pod Labels:
295313
Pod Security Context:
296314
Readiness Probe:
297315
Resources:
298316
Limits:
299317
Requests:
300-
Service Annotations:
301-
Service Labels:
302318
Volume Mounts:
303319
Volumes:
320+
Server Service:
321+
Annotations:
322+
Labels:
304323
Server Start Policy: IF_NEEDED
305324
Web Logic Credentials Secret:
306325
Name: domain1-weblogic-credentials
307326
Status:
308327
Conditions:
309-
Last Transition Time: 2018-12-17T05:59:55.227Z
328+
Last Transition Time: 2019-01-10T14:31:10.681Z
310329
Reason: ServersReady
311330
Status: True
312331
Type: Available
313332
Servers:
314333
Health:
315-
Activation Time: 2018-12-17T05:59:37.977Z
334+
Activation Time: 2019-01-10T14:30:47.432Z
316335
Overall Health: ok
317336
Subsystems:
318-
Node Name: xxxxxxxx
337+
Node Name: slc16ffk
319338
Server Name: admin-server
320339
State: RUNNING
321340
Cluster Name: cluster-1
322341
Health:
323-
Activation Time: 2018-12-17T06:01:23.764Z
342+
Activation Time: 2019-01-10T14:32:01.467Z
324343
Overall Health: ok
325344
Subsystems:
326-
Node Name: xxxxxxxx
345+
Node Name: slc16ffk
327346
Server Name: managed-server1
328347
State: RUNNING
329348
Cluster Name: cluster-1
330349
Health:
331-
Activation Time: 2018-12-17T06:01:25.393Z
350+
Activation Time: 2019-01-10T14:32:04.532Z
332351
Overall Health: ok
333352
Subsystems:
334-
Node Name: xxxxxxxx
335-
Server Name: managed-server2
353+
Node Name: slc16ffk
354+
Server Name: managed-server2
336355
State: RUNNING
337-
Start Time: 2018-12-17T05:58:12.615Z
338-
Events: <none>
356+
Start Time: 2019-01-10T14:29:37.455Z
357+
Events: <none>
339358
```
340359

341360
In the `Status` section of the output, the available servers and clusters are listed. Note that if this command is issued very soon after the script finishes, there may be no servers available yet, or perhaps only the Administration Server but no Managed Servers. The operator will start up the Administration Server first and wait for it to become ready before starting the Managed Servers.

kubernetes/samples/scripts/create-weblogic-domain/domain-home-in-image/create-domain-inputs.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2018, Oracle Corporation and/or its affiliates. All rights reserved.
1+
# Copyright 2018, 2019, Oracle Corporation and/or its affiliates. All rights reserved.
22
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
33

44
# The version of this inputs file. Do not modify.
@@ -74,8 +74,7 @@ includeServerOutInPodLog: true
7474
# The default is false.
7575
logHomeOnPV: false
7676

77-
# The in-pod name of the directory in which to store the domain, node manager, server logs,
78-
# and server .out files.
77+
# The in-pod location for domain log, server logs, server out, and node manager log files
7978
# If not specified, the value is derived from the domainUID as /shared/logs/<domainUID>
8079
# This parameter is required if 'logHomeOnPV' is true.
8180
# Otherwise, it is ignored.

0 commit comments

Comments
 (0)