Quantcast

Subject: Re: old problem with environment variables

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Subject: Re: old problem with environment variables

Grant MacKenzie
>> I need to set environment variables which are available to my exist 3.1.1 run as a service with y on Linux 3.13.0-110. I had them set in the wrapper.conf once upon a time in exist 2.2, but modifying in the same way the current wrapper.conf of yajsw does not have the same effect. Where and how should I set environment variables for them to be available to exist? setting them from the shell normally does not make them available to available-environment-variables().

I haven't looked into yajsw, but if you have a relatively modern linux
versionyou can start eXist as a systemd service.
This is where I set the enviroment var. My understanding is that you
can't do this via the Shell cause init is prior to the (bash) shell
login environment kicking in.

exist.service example ..

[Unit]
Description=The exist db application server
After=network.target

[Service]
Environment="EXIST_HOME=/usr/local/eXist"
Environment="SERVER=development"

--
Take Care
Grant Mackenzie

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Subject: Re: old problem with environment variables

Adam Retter
If you search for "Environment Variables" within this page -
http://yajsw.sourceforge.net/Migrating%20from%20JSW.html it might help
you

On 25 March 2017 at 01:19, Grant MacKenzie <[hidden email]> wrote:

>>> I need to set environment variables which are available to my exist 3.1.1 run as a service with y on Linux 3.13.0-110. I had them set in the wrapper.conf once upon a time in exist 2.2, but modifying in the same way the current wrapper.conf of yajsw does not have the same effect. Where and how should I set environment variables for them to be available to exist? setting them from the shell normally does not make them available to available-environment-variables().
>
> I haven't looked into yajsw, but if you have a relatively modern linux
> versionyou can start eXist as a systemd service.
> This is where I set the enviroment var. My understanding is that you
> can't do this via the Shell cause init is prior to the (bash) shell
> login environment kicking in.
>
> exist.service example ..
>
> [Unit]
> Description=The exist db application server
> After=network.target
>
> [Service]
> Environment="EXIST_HOME=/usr/local/eXist"
> Environment="SERVER=development"
>
> --
> Take Care
> Grant Mackenzie
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Exist-open mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/exist-open



--
Adam Retter

eXist Developer
{ United Kingdom }
[hidden email]
irc://irc.freenode.net/existdb

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Subject: Re: old problem with environment variables

Pietro Liuzzo
thanks! 

it worked setting the variable as

wrapper.app.env.VARIABLENAME=VALUE

2017-03-25 14:37 GMT+01:00 Adam Retter <[hidden email]>:
If you search for "Environment Variables" within this page -
http://yajsw.sourceforge.net/Migrating%20from%20JSW.html it might help
you

On 25 March 2017 at 01:19, Grant MacKenzie <[hidden email]> wrote:
>>> I need to set environment variables which are available to my exist 3.1.1 run as a service with y on Linux 3.13.0-110. I had them set in the wrapper.conf once upon a time in exist 2.2, but modifying in the same way the current wrapper.conf of yajsw does not have the same effect. Where and how should I set environment variables for them to be available to exist? setting them from the shell normally does not make them available to available-environment-variables().
>
> I haven't looked into yajsw, but if you have a relatively modern linux
> versionyou can start eXist as a systemd service.
> This is where I set the enviroment var. My understanding is that you
> can't do this via the Shell cause init is prior to the (bash) shell
> login environment kicking in.
>
> exist.service example ..
>
> [Unit]
> Description=The exist db application server
> After=network.target
>
> [Service]
> Environment="EXIST_HOME=/usr/local/eXist"
> Environment="SERVER=development"
>
> --
> Take Care
> Grant Mackenzie
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Exist-open mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/exist-open



--
Adam Retter

eXist Developer
{ United Kingdom }
[hidden email]
irc://irc.freenode.net/existdb

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open



--
Pietro Maria Liuzzo
cel (DE): +49 (0) 176 61 000 606
Skype: pietro.liuzzo (Quingentole)

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Loading...