[OSGeoLive] OSGeoLive Environment Variable

Johan Van de Wauw johan.vandewauw at gmail.com
Wed Sep 9 00:28:02 PDT 2020

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).
echo "export OSGEOLIVE=$VERSION">/etc/profile.d/osgeolive.sh should do the

On Tue, Sep 8, 2020, 22:26 Seth G <sethg at geographika.co.uk> wrote:

> 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 OSGeoLive.
> Setting an OSGEOLIVE variable to the version could be even more helpful
> e.g. "export OSGEOLIVE=14" (somewhere in
> https://github.com/OSGeo/OSGeoLive/tree/master/bin - although I'm not
> sure where). As noted in IRC from kalxas "we can add this to the bash
> profile of new users" - so maybe in
> https://github.com/OSGeo/OSGeoLive/blob/master/bin/setup.sh ?
> "export OSGEOLIVE=true" or similar could be used if keeping version
> numbers updated is a problem.
> Then any demos could be multipurposed - running in cloud plus running on
> osgeolive and setting appropriate paths to data if that is the case.
> Seth
> --
> web:http://geographika.co.uk
> twitter: @geographika
> _______________________________________________
> osgeolive mailing list
> osgeolive at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/osgeolive
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/osgeolive/attachments/20200909/c3ef37a2/attachment.html>

More information about the osgeolive mailing list