Re: [OSGeoLive] OSGeoLive Environment Variable

2020-09-09 Thread Seth G
Hi Jim, The main benefit would be that notebooks/demos could be configured independently of OSGeoLive releases and have the same code for multiple environments. For example the notebook at [1] can be run on MyBinder and OSGeoLive. Seth [1] https://github.com/geographika/GeoPythonNotebooks/b

Re: [OSGeoLive] OSGeoLive Environment Variable

2020-09-09 Thread Seth G
Thanks Johan - this looks like it would do the trick. I'll setup up a pull request. -- web:http://geographika.co.uk twitter: @geographika On Wed, Sep 9, 2020, at 9:28 AM, Johan Van de Wauw wrote: > If you add a script to /etc/profile.d/ it will be sourced to all interactive > users. > I would

Re: [OSGeoLive] OSGeoLive Environment Variable

2020-09-09 Thread Johan Van de Wauw
If you add a script to /etc/profile.d/ it will be sourced to all interactive users. I would use the version number, this version number is available while building the image ($VERSION). adding echo "export OSGEOLIVE=$VERSION">/etc/profile.d/osgeolive.sh should do the trick. On Tue, Sep 8, 2020, 22

Re: [OSGeoLive] OSGeoLive Environment Variable

2020-09-08 Thread Jim Klassen
I'm probably missing something obvious here, but it seems odd to me to make OSGeoLive a special case at runtime.  Wouldn't it make more sense to have the OSGeoLive install_*.sh file configure the application for the paths on OSGeoLive (which may include setting an environment variable to point

[OSGeoLive] OSGeoLive Environment Variable

2020-09-08 Thread Seth G
Hi list, It would be useful for a Python Notebook (or any demo application) to know if it is running on OSGeoLive in order to set paths to data etc. Looking at the current system environment variables I don't think there is something that would definitively declare a script is running on OSGeo