Add legacy URL handling and update environment configurations
All checks were successful
Publish FaceAI Container / publish (push) Successful in 2m25s

This commit is contained in:
MaddoScientisto 2026-04-19 08:48:15 +02:00
commit f757f8af1d
11 changed files with 79 additions and 28 deletions

View file

@ -52,10 +52,11 @@
</jsp:useBean>
<%
String faceAiFeatureEnabledValue = System.getenv("FACEAI_FEATURE_ENABLED");
if (faceAiFeatureEnabledValue == null) {
faceAiFeatureEnabledValue = System.getProperty("FACEAI_FEATURE_ENABLED", "0");
if (faceAiFeatureEnabledValue == null || faceAiFeatureEnabledValue.trim().length() == 0) {
faceAiFeatureEnabledValue = System.getProperty("FACEAI_FEATURE_ENABLED", "1");
}
boolean faceAiFeatureEnabled = "1".equals(faceAiFeatureEnabledValue) || "true".equalsIgnoreCase(faceAiFeatureEnabledValue) || "yes".equalsIgnoreCase(faceAiFeatureEnabledValue) || "on".equalsIgnoreCase(faceAiFeatureEnabledValue);
String faceAiFeatureEnabledNormalized = faceAiFeatureEnabledValue != null ? faceAiFeatureEnabledValue.trim() : "";
boolean faceAiFeatureEnabled = !("0".equals(faceAiFeatureEnabledNormalized) || "false".equalsIgnoreCase(faceAiFeatureEnabledNormalized) || "no".equalsIgnoreCase(faceAiFeatureEnabledNormalized) || "off".equalsIgnoreCase(faceAiFeatureEnabledNormalized));
java.util.Date faceAiRaceDate = CR.getGara().getDataGaraInizio();
String faceAiRacePathBase = CR.getGara().getPathBase() != null ? CR.getGara().getPathBase().trim() : "";
String faceAiRaceYear = "";

View file

@ -52,10 +52,11 @@
</jsp:useBean>
<%
String faceAiFeatureEnabledValue = System.getenv("FACEAI_FEATURE_ENABLED");
if (faceAiFeatureEnabledValue == null) {
faceAiFeatureEnabledValue = System.getProperty("FACEAI_FEATURE_ENABLED", "0");
if (faceAiFeatureEnabledValue == null || faceAiFeatureEnabledValue.trim().length() == 0) {
faceAiFeatureEnabledValue = System.getProperty("FACEAI_FEATURE_ENABLED", "1");
}
boolean faceAiFeatureEnabled = "1".equals(faceAiFeatureEnabledValue) || "true".equalsIgnoreCase(faceAiFeatureEnabledValue) || "yes".equalsIgnoreCase(faceAiFeatureEnabledValue) || "on".equalsIgnoreCase(faceAiFeatureEnabledValue);
String faceAiFeatureEnabledNormalized = faceAiFeatureEnabledValue != null ? faceAiFeatureEnabledValue.trim() : "";
boolean faceAiFeatureEnabled = !("0".equals(faceAiFeatureEnabledNormalized) || "false".equalsIgnoreCase(faceAiFeatureEnabledNormalized) || "no".equalsIgnoreCase(faceAiFeatureEnabledNormalized) || "off".equalsIgnoreCase(faceAiFeatureEnabledNormalized));
java.util.Date faceAiRaceDate = CR.getGara().getDataGaraInizio();
String faceAiRacePathBase = CR.getGara().getPathBase() != null ? CR.getGara().getPathBase().trim() : "";
String faceAiRaceYear = "";