dhis2-users team mailing list archive
-
dhis2-users team
-
Mailing list archive
-
Message #10632
Re: Populating hibernate.properties with environment variables
Hello Lars,
Thank you very much. I am running DHIS 2.18 on Heroku with PostgreSQL.
Heroku provides database connection parameters via certain environment
variables. For now, I am hard-coding all these parameters into the
config/hibernate.properties file. So, whenever the database is reset
or re-provisioned, DHIS 2.18 needs to be redeployed with another
configuration. That's why I was looking to use environment variables
inside the file.
I found a similar configuration here at
http://hsqldb.org/doc/guide/dbproperties-chapt.html#dpc_system_props
but I don't know whether it is applicable for DHIS2. It says that
${environment-variable} will work.
Regards,
Aatish Neupane
On Fri, Jul 1, 2016 at 11:00 PM, Lars Helge Øverland <lars@xxxxxxxxx> wrote:
> Hi Aatish,
>
> no you cannot. If you let us know your problem we could perhaps help.
>
> regards,
>
> Lars
>
> On Jul 1, 2016 5:25 PM, "Aatish Neupane" <aatishnn@xxxxxxxxx> wrote:
>>
>> Hello,
>>
>> Is it possible to use environment variables in hibernate.properties
>> file? I am using DHIS 2.18.
>>
>> Regards,
>> Aatish Neupane
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~dhis2-users
>> Post to : dhis2-users@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~dhis2-users
>> More help : https://help.launchpad.net/ListHelp
References