Skip to content

Commit 134860d

Browse files
leochrkabicin
authored andcommitted
Update kernel Dockerfiles for serviceability
1 parent 73fa868 commit 134860d

11 files changed

+153
-59
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
- [WebSphere Application Server Liberty and Containers](#websphere-application-server-liberty-and-containers)
44
- [Container images](#container-images)
55
- [Building an application image](#building-an-application-image)
6-
- [Optional Enterprise Functionality](#optional-enterprise-functionality)
6+
- [Build Variables](#build-variables)
77
- [Security](#security)
88
- [OpenJ9 Shared Class Cache (SCC)](#openj9-shared-class-cache-scc)
99
- [Logging](#logging)
@@ -65,11 +65,11 @@ remoteRepo.user=operator
6565
remoteRepo.password={aes}KM8dhwcv892Ss1sawu9R+
6666
```
6767

68-
Refer to [Repository and proxy modifications](https://openliberty.io/docs/ref/command/featureUtility-modifications.html) for more information.
68+
Refer to [Repository and proxy modifications](https://openliberty.io/docs/ref/command/featureUtility-commands.html) for more information.
6969

70-
## Optional Enterprise Functionality
70+
## Build Variables
7171

72-
This section describes the optional enterprise functionality that can be enabled via the Dockerfile during `build` time, by setting particular argument (`ARG`) or environment variable (`ENV`) and calling `RUN configure.sh`. Each of these options trigger the inclusion of specific configuration via XML snippets (except for `VERBOSE` and `SKIP_FEATURE_INSTALL`), described below:
72+
This section describes the optional build variables that can be enabled via the Dockerfile during the `build` time, by setting particular build-argument (`ARG`) or environment variable (`ENV`) and calling `RUN configure.sh`. Each of these variables trigger the inclusion of specific configuration via XML snippets (except for `VERBOSE` and `SKIP_FEATURE_INSTALL`), described below:
7373

7474
* `HZ_SESSION_CACHE`
7575
* Description: Enable the persistence of HTTP sessions using JCache by adding the `sessionCache-1.0` feature.
@@ -83,9 +83,9 @@ This section describes the optional enterprise functionality that can be enabled
8383
* Description: When set to `true` it outputs the commands and results to stdout from `configure.sh`. Otherwise, default setting is `false` and `configure.sh` is silenced.
8484

8585

86-
### Deprecated Enterprise Functionality
86+
### Deprecated Build Variables
8787

88-
The following enterprise functionalities are now **deprecated** and will be **removed** in a future release. You should **stop** using them :
88+
The following container image build variables are now **deprecated** and will be **removed** in a future release. You should **stop** using them:
8989

9090
* `HTTP_ENDPOINT`
9191
* Description: Add configuration properties for an HTTP endpoint.

docs/icr-images.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ ibmcloud cr images --restrict appcafe/websphere-liberty
3030

3131
## Latest version
3232

33-
The following tags include the most recent WebSphere Liberty version: `25.0.0.1`
33+
The following tags include the most recent WebSphere Liberty version: `25.0.0.2`
3434

3535
```
3636
kernel-java21-openj9-ubi-minimal
@@ -48,20 +48,20 @@ full-java8-ibmjava-ubi
4848
latest
4949
```
5050

51-
## 25.0.0.1
51+
## 25.0.0.2
5252

5353
```
54-
25.0.0.1-kernel-java21-openj9-ubi-minimal
55-
25.0.0.1-kernel-java17-openj9-ubi
56-
25.0.0.1-kernel-java11-openj9-ubi
57-
25.0.0.1-kernel-java8-ibmjava-ubi
58-
25.0.0.1-kernel-java8-openj9-ubi
59-
60-
25.0.0.1-full-java21-openj9-ubi-minimal
61-
25.0.0.1-full-java17-openj9-ubi
62-
25.0.0.1-full-java11-openj9-ubi
63-
25.0.0.1-full-java8-openj9-ubi
64-
25.0.0.1-full-java8-ibmjava-ubi
54+
25.0.0.2-kernel-java21-openj9-ubi-minimal
55+
25.0.0.2-kernel-java17-openj9-ubi
56+
25.0.0.2-kernel-java11-openj9-ubi
57+
25.0.0.2-kernel-java8-ibmjava-ubi
58+
25.0.0.2-kernel-java8-openj9-ubi
59+
60+
25.0.0.2-full-java21-openj9-ubi-minimal
61+
25.0.0.2-full-java17-openj9-ubi
62+
25.0.0.2-full-java11-openj9-ubi
63+
25.0.0.2-full-java8-openj9-ubi
64+
25.0.0.2-full-java8-ibmjava-ubi
6565
```
6666

6767
## 24.0.0.12

ga/latest/kernel/Dockerfile.ubi.ibmjava8

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,7 @@ COPY helpers/ /opt/ibm/helpers/
131131
COPY fixes/ /opt/ibm/fixes/
132132

133133
# Create symlinks && set permissions for non-root user
134-
RUN mkdir /logs \
135-
&& mkdir /etc/wlp \
134+
RUN mkdir /etc/wlp \
136135
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
137136
&& mkdir -p /home/default \
138137
&& mkdir /output \
@@ -155,12 +154,24 @@ RUN mkdir /logs \
155154
&& chmod -R g+rw /opt/ibm/wlp/usr \
156155
&& chown -R 1001:0 /opt/ibm/wlp/output \
157156
&& chmod -R g+rw /opt/ibm/wlp/output \
158-
&& chown -R 1001:0 /logs \
159-
&& chmod -R g+rw /logs \
160157
&& chown -R 1001:0 /etc/wlp \
161158
&& chmod -R g+rw /etc/wlp \
162159
&& chown -R 1001:0 /home/default \
163-
&& chmod -R g+rw /home/default
160+
&& chmod -R g+rw /home/default \
161+
&& mkdir -p /opt/ibm/links \
162+
&& chown -R 1001:0 /opt/ibm/links \
163+
&& chmod -R g+rw /opt/ibm/links \
164+
&& mkdir -p /opt/ibm/logs \
165+
&& chown -R 1001:0 /opt/ibm/logs \
166+
&& chmod -R g+rw /opt/ibm/logs \
167+
&& mkdir -p /serviceability \
168+
&& chown -R 1001:0 /serviceability \
169+
&& chmod -R g+rw /serviceability
170+
171+
USER 1001
172+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
173+
USER root
174+
RUN ln -s /opt/ibm/links/logs /logs
164175

165176
# Create a new SCC layer
166177
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubi.openjdk11

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -132,8 +132,7 @@ COPY helpers/ /opt/ibm/helpers/
132132
COPY fixes/ /opt/ibm/fixes/
133133

134134
# Create symlinks && set permissions for non-root user
135-
RUN mkdir /logs \
136-
&& mkdir /etc/wlp \
135+
RUN mkdir /etc/wlp \
137136
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
138137
&& mkdir -p /home/default \
139138
&& mkdir /output \
@@ -156,13 +155,25 @@ RUN mkdir /logs \
156155
&& chmod -R g+rw /opt/ibm/wlp/usr \
157156
&& chown -R 1001:0 /opt/ibm/wlp/output \
158157
&& chmod -R g+rw /opt/ibm/wlp/output \
159-
&& chown -R 1001:0 /logs \
160-
&& chmod -R g+rw /logs \
161158
&& chown -R 1001:0 /etc/wlp \
162159
&& chmod -R g+rw /etc/wlp \
163160
&& if [ -e /etc/instanton.ld.so.cache ]; then chmod g+w /etc/ld.so.cache; fi \
164161
&& chown -R 1001:0 /home/default \
165-
&& chmod -R g+rw /home/default
162+
&& chmod -R g+rw /home/default \
163+
&& mkdir -p /opt/ibm/links \
164+
&& chown -R 1001:0 /opt/ibm/links \
165+
&& chmod -R g+rw /opt/ibm/links \
166+
&& mkdir -p /opt/ibm/logs \
167+
&& chown -R 1001:0 /opt/ibm/logs \
168+
&& chmod -R g+rw /opt/ibm/logs \
169+
&& mkdir -p /serviceability \
170+
&& chown -R 1001:0 /serviceability \
171+
&& chmod -R g+rw /serviceability
172+
173+
USER 1001
174+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
175+
USER root
176+
RUN ln -s /opt/ibm/links/logs /logs
166177

167178
# Create a new SCC layer
168179
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubi.openjdk17

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,7 @@ COPY helpers/ /opt/ibm/helpers/
131131
COPY fixes/ /opt/ibm/fixes/
132132

133133
# Create symlinks && set permissions for non-root user
134-
RUN mkdir /logs \
135-
&& mkdir /etc/wlp \
134+
RUN mkdir /etc/wlp \
136135
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
137136
&& mkdir -p /home/default \
138137
&& mkdir /output \
@@ -155,13 +154,25 @@ RUN mkdir /logs \
155154
&& chmod -R g+rw /opt/ibm/wlp/usr \
156155
&& chown -R 1001:0 /opt/ibm/wlp/output \
157156
&& chmod -R g+rw /opt/ibm/wlp/output \
158-
&& chown -R 1001:0 /logs \
159-
&& chmod -R g+rw /logs \
160157
&& chown -R 1001:0 /etc/wlp \
161158
&& chmod -R g+rw /etc/wlp \
162159
&& if [ -e /etc/instanton.ld.so.cache ]; then chmod g+w /etc/ld.so.cache; fi \
163160
&& chown -R 1001:0 /home/default \
164-
&& chmod -R g+rw /home/default
161+
&& chmod -R g+rw /home/default \
162+
&& mkdir -p /opt/ibm/links \
163+
&& chown -R 1001:0 /opt/ibm/links \
164+
&& chmod -R g+rw /opt/ibm/links \
165+
&& mkdir -p /opt/ibm/logs \
166+
&& chown -R 1001:0 /opt/ibm/logs \
167+
&& chmod -R g+rw /opt/ibm/logs \
168+
&& mkdir -p /serviceability \
169+
&& chown -R 1001:0 /serviceability \
170+
&& chmod -R g+rw /serviceability
171+
172+
USER 1001
173+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
174+
USER root
175+
RUN ln -s /opt/ibm/links/logs /logs
165176

166177
# Create a new SCC layer
167178
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubi.openjdk21

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,7 @@ COPY helpers/ /opt/ibm/helpers/
131131
COPY fixes/ /opt/ibm/fixes/
132132

133133
# Create symlinks && set permissions for non-root user
134-
RUN mkdir /logs \
135-
&& mkdir /etc/wlp \
134+
RUN mkdir /etc/wlp \
136135
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
137136
&& mkdir -p /home/default \
138137
&& mkdir /output \
@@ -155,13 +154,25 @@ RUN mkdir /logs \
155154
&& chmod -R g+rw /opt/ibm/wlp/usr \
156155
&& chown -R 1001:0 /opt/ibm/wlp/output \
157156
&& chmod -R g+rw /opt/ibm/wlp/output \
158-
&& chown -R 1001:0 /logs \
159-
&& chmod -R g+rw /logs \
160157
&& chown -R 1001:0 /etc/wlp \
161158
&& chmod -R g+rw /etc/wlp \
162159
&& if [ -e /etc/instanton.ld.so.cache ]; then chmod g+w /etc/ld.so.cache; fi \
163160
&& chown -R 1001:0 /home/default \
164-
&& chmod -R g+rw /home/default
161+
&& chmod -R g+rw /home/default \
162+
&& mkdir -p /opt/ibm/links \
163+
&& chown -R 1001:0 /opt/ibm/links \
164+
&& chmod -R g+rw /opt/ibm/links \
165+
&& mkdir -p /opt/ibm/logs \
166+
&& chown -R 1001:0 /opt/ibm/logs \
167+
&& chmod -R g+rw /opt/ibm/logs \
168+
&& mkdir -p /serviceability \
169+
&& chown -R 1001:0 /serviceability \
170+
&& chmod -R g+rw /serviceability
171+
172+
USER 1001
173+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
174+
USER root
175+
RUN ln -s /opt/ibm/links/logs /logs
165176

166177
# Create a new SCC layer
167178
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubi.openjdk8

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,7 @@ COPY helpers/ /opt/ibm/helpers/
131131
COPY fixes/ /opt/ibm/fixes/
132132

133133
# Create symlinks && set permissions for non-root user
134-
RUN mkdir /logs \
135-
&& mkdir /etc/wlp \
134+
RUN mkdir /etc/wlp \
136135
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
137136
&& mkdir -p /home/default \
138137
&& mkdir /output \
@@ -155,13 +154,25 @@ RUN mkdir /logs \
155154
&& chmod -R g+rw /opt/ibm/wlp/usr \
156155
&& chown -R 1001:0 /opt/ibm/wlp/output \
157156
&& chmod -R g+rw /opt/ibm/wlp/output \
158-
&& chown -R 1001:0 /logs \
159-
&& chmod -R g+rw /logs \
160157
&& chown -R 1001:0 /etc/wlp \
161158
&& chmod -R g+rw /etc/wlp \
162159
&& if [ -e /etc/instanton.ld.so.cache ]; then chmod g+w /etc/ld.so.cache; fi \
163160
&& chown -R 1001:0 /home/default \
164-
&& chmod -R g+rw /home/default
161+
&& chmod -R g+rw /home/default \
162+
&& mkdir -p /opt/ibm/links \
163+
&& chown -R 1001:0 /opt/ibm/links \
164+
&& chmod -R g+rw /opt/ibm/links \
165+
&& mkdir -p /opt/ibm/logs \
166+
&& chown -R 1001:0 /opt/ibm/logs \
167+
&& chmod -R g+rw /opt/ibm/logs \
168+
&& mkdir -p /serviceability \
169+
&& chown -R 1001:0 /serviceability \
170+
&& chmod -R g+rw /serviceability
171+
172+
USER 1001
173+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
174+
USER root
175+
RUN ln -s /opt/ibm/links/logs /logs
165176

166177
# Create a new SCC layer
167178
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubuntu.ibmjava8

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,7 @@ COPY helpers/ /opt/ibm/helpers/
112112
COPY fixes/ /opt/ibm/fixes/
113113

114114
# Create symlinks && set permissions for non-root user
115-
RUN mkdir /logs \
116-
&& mkdir /etc/wlp \
115+
RUN mkdir /etc/wlp \
117116
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
118117
&& mkdir -p /home/default \
119118
&& mkdir /output \
@@ -136,12 +135,24 @@ RUN mkdir /logs \
136135
&& chmod -R g+rw /opt/ibm/wlp/usr \
137136
&& chown -R 1001:0 /opt/ibm/wlp/output \
138137
&& chmod -R g+rw /opt/ibm/wlp/output \
139-
&& chown -R 1001:0 /logs \
140-
&& chmod -R g+rw /logs \
141138
&& chown -R 1001:0 /etc/wlp \
142139
&& chmod -R g+rw /etc/wlp \
143140
&& chown -R 1001:0 /home/default \
144-
&& chmod -R g+rw /home/default
141+
&& chmod -R g+rw /home/default \
142+
&& mkdir -p /opt/ibm/links \
143+
&& chown -R 1001:0 /opt/ibm/links \
144+
&& chmod -R g+rw /opt/ibm/links \
145+
&& mkdir -p /opt/ibm/logs \
146+
&& chown -R 1001:0 /opt/ibm/logs \
147+
&& chmod -R g+rw /opt/ibm/logs \
148+
&& mkdir -p /serviceability \
149+
&& chown -R 1001:0 /serviceability \
150+
&& chmod -R g+rw /serviceability
151+
152+
USER 1001
153+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
154+
USER root
155+
RUN ln -s /opt/ibm/links/logs /logs
145156

146157
# Create a new SCC layer
147158
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubuntu.openjdk11

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,7 @@ COPY helpers/ /opt/ibm/helpers/
107107
COPY fixes/ /opt/ibm/fixes/
108108

109109
# Create symlinks && set permissions for non-root user
110-
RUN mkdir /logs \
111-
&& mkdir /etc/wlp \
110+
RUN mkdir /etc/wlp \
112111
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
113112
&& mkdir -p /home/default \
114113
&& mkdir /output \
@@ -131,12 +130,24 @@ RUN mkdir /logs \
131130
&& chmod -R g+rw /opt/ibm/wlp/usr \
132131
&& chown -R 1001:0 /opt/ibm/wlp/output \
133132
&& chmod -R g+rw /opt/ibm/wlp/output \
134-
&& chown -R 1001:0 /logs \
135-
&& chmod -R g+rw /logs \
136133
&& chown -R 1001:0 /etc/wlp \
137134
&& chmod -R g+rw /etc/wlp \
138135
&& chown -R 1001:0 /home/default \
139-
&& chmod -R g+rw /home/default
136+
&& chmod -R g+rw /home/default \
137+
&& mkdir -p /opt/ibm/links \
138+
&& chown -R 1001:0 /opt/ibm/links \
139+
&& chmod -R g+rw /opt/ibm/links \
140+
&& mkdir -p /opt/ibm/logs \
141+
&& chown -R 1001:0 /opt/ibm/logs \
142+
&& chmod -R g+rw /opt/ibm/logs \
143+
&& mkdir -p /serviceability \
144+
&& chown -R 1001:0 /serviceability \
145+
&& chmod -R g+rw /serviceability
146+
147+
USER 1001
148+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
149+
USER root
150+
RUN ln -s /opt/ibm/links/logs /logs
140151

141152
# Create a new SCC layer
142153
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/Dockerfile.ubuntu.openjdk17

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,7 @@ COPY helpers/ /opt/ibm/helpers/
107107
COPY fixes/ /opt/ibm/fixes/
108108

109109
# Create symlinks && set permissions for non-root user
110-
RUN mkdir /logs \
111-
&& mkdir /etc/wlp \
110+
RUN mkdir /etc/wlp \
112111
&& mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \
113112
&& mkdir -p /home/default \
114113
&& mkdir /output \
@@ -131,12 +130,24 @@ RUN mkdir /logs \
131130
&& chmod -R g+rw /opt/ibm/wlp/usr \
132131
&& chown -R 1001:0 /opt/ibm/wlp/output \
133132
&& chmod -R g+rw /opt/ibm/wlp/output \
134-
&& chown -R 1001:0 /logs \
135-
&& chmod -R g+rw /logs \
136133
&& chown -R 1001:0 /etc/wlp \
137134
&& chmod -R g+rw /etc/wlp \
138135
&& chown -R 1001:0 /home/default \
139-
&& chmod -R g+rw /home/default
136+
&& chmod -R g+rw /home/default \
137+
&& mkdir -p /opt/ibm/links \
138+
&& chown -R 1001:0 /opt/ibm/links \
139+
&& chmod -R g+rw /opt/ibm/links \
140+
&& mkdir -p /opt/ibm/logs \
141+
&& chown -R 1001:0 /opt/ibm/logs \
142+
&& chmod -R g+rw /opt/ibm/logs \
143+
&& mkdir -p /serviceability \
144+
&& chown -R 1001:0 /serviceability \
145+
&& chmod -R g+rw /serviceability
146+
147+
USER 1001
148+
RUN ln -s /opt/ibm/logs /opt/ibm/links/logs
149+
USER root
150+
RUN ln -s /opt/ibm/links/logs /logs
140151

141152
# Create a new SCC layer
142153
RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \

ga/latest/kernel/helpers/runtime/docker-server.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,5 +155,11 @@ elif [[ ! -z "$WLP_CHECKPOINT" ]]; then
155155
checkpoint.sh "$TMP_CHECKPOINT"
156156
else
157157
# The default is to just exec the supplied CMD
158+
if [[ ! -z "$SERVICEABILITY_NAMESPACE" ]] && [[ ! -z $HOSTNAME ]]; then
159+
SERVICEABILITY_FOLDER="/serviceability/$SERVICEABILITY_NAMESPACE/$HOSTNAME"
160+
mkdir -p $SERVICEABILITY_FOLDER
161+
rm -f /opt/ibm/links/logs
162+
ln -s $SERVICEABILITY_FOLDER /opt/ibm/links/logs
163+
fi
158164
exec "$@"
159165
fi

0 commit comments

Comments
 (0)