chore: fix incorrect env var names in backend loader

This commit is contained in:
Emmanuel BENOîT 2025-01-03 16:58:18 +01:00
parent 00c6b2ba1e
commit 1be81334ce
Signed by: Emmanuel BENOîT
SSH key fingerprint: SHA256:l7PFUUF5TCDsvYeQC9OnTNz08dFY7Fvf4Hv3neIqYpg

View file

@ -3,10 +3,10 @@
cd /app cd /app
if ! [ -z "$LW_CONFIGURE" ]; then if ! [ -z "$LW_CONFIGURE" ]; then
if [ -z "$DB_PASSWORD_FILE" ]; then if [ -z "$LW_DB_PASSWORD_FILE" ]; then
password="$DB_PASSWORD" password="$LW_DB_PASSWORD"
else else
password="`cat $DB_PASSWORD_FILE`" password="`cat $LW_DB_PASSWORD_FILE`"
fi fi
cat >data-source.xml <<EOF cat >data-source.xml <<EOF
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
@ -15,8 +15,8 @@ if ! [ -z "$LW_CONFIGURE" ]; then
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd"> xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
<bean name="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"> <bean name="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
<property name="driverClassName" value="org.postgresql.Driver" /> <property name="driverClassName" value="org.postgresql.Driver" />
<property name="url" value="jdbc:postgresql://${DB_HOST}:5432/${DB_NAME}" /> <property name="url" value="jdbc:postgresql://${LW_DB_HOST}:5432/${LW_DB_NAME}" />
<property name="username" value="${DB_USER}" /> <property name="username" value="${LW_DB_USER}" />
<property name="password" value="${password}" /> <property name="password" value="${password}" />
</bean> </bean>
</beans> </beans>