|
94 | 94 | import static oracle.kubernetes.operator.helpers.EventHelper.EventItem.DOMAIN_ROLL_STARTING;
|
95 | 95 | import static oracle.kubernetes.operator.helpers.EventHelper.EventItem.POD_CYCLE_STARTING;
|
96 | 96 | import static oracle.kubernetes.operator.helpers.LegalNames.LEGAL_CONTAINER_PORT_NAME_MAX_LENGTH;
|
| 97 | +import static oracle.kubernetes.utils.OperatorUtils.isNullOrEmpty; |
97 | 98 | import static oracle.kubernetes.weblogic.domain.model.Model.DEFAULT_WDT_INSTALL_HOME;
|
| 99 | +import static oracle.kubernetes.weblogic.domain.model.Model.DEFAULT_WDT_MODEL_HOME; |
98 | 100 |
|
99 | 101 | public abstract class PodStepContext extends BasePodStepContext {
|
100 | 102 |
|
@@ -963,9 +965,13 @@ void addStartupEnvVars(List<V1EnvVar> vars, TuningParameters tuningParameters) {
|
963 | 965 | addEnvVar(vars, ServerEnvVars.AS_SERVICE_NAME, LegalNames.toServerServiceName(getDomainUid(), getAsName()));
|
964 | 966 | Optional.ofNullable(getDataHome()).ifPresent(v -> addEnvVar(vars, ServerEnvVars.DATA_HOME, v));
|
965 | 967 | String wdtInstallHome = getWdtInstallHome();
|
966 |
| - if (wdtInstallHome != null && !wdtInstallHome.isEmpty() && !wdtInstallHome.equals(DEFAULT_WDT_INSTALL_HOME)) { |
| 968 | + if (!isNullOrEmpty(wdtInstallHome) && !wdtInstallHome.equals(DEFAULT_WDT_INSTALL_HOME)) { |
967 | 969 | addEnvVar(vars, IntrospectorJobEnvVars.WDT_INSTALL_HOME, wdtInstallHome);
|
968 | 970 | }
|
| 971 | + String modelHome = getModelHome(); |
| 972 | + if (!isNullOrEmpty(modelHome) && !modelHome.equals(DEFAULT_WDT_MODEL_HOME)) { |
| 973 | + addEnvVar(vars, IntrospectorJobEnvVars.WDT_MODEL_HOME, modelHome); |
| 974 | + } |
969 | 975 | Optional.ofNullable(getServerSpec().getAuxiliaryImages()).ifPresent(cm -> addAuxiliaryImageEnv(cm, vars));
|
970 | 976 | addEnvVarIfTrue(mockWls(), vars, "MOCK_WLS");
|
971 | 977 | Optional.ofNullable(getKubernetesPlatform(tuningParameters)).ifPresent(v ->
|
|
0 commit comments