equinor / komodoenv

Komodoenv is the virtualenv of the Komodo world
GNU General Public License v3.0
1 stars 3 forks source link

Piggyback on komodo's enable's envvars #4

Closed pinkwah closed 3 years ago

pinkwah commented 3 years ago

We were setting a custom KOMODOENV_PREFIX variable. Instead, following path of least resistance, we'll only use variables that komodo itself sets. Thus, KOMODO_RELEASE was previously the name of the release (eg. 2020.03.01-py27)

With this, we set KOMODO_RELEASE to be the full path to the user's komodoenv. komodo_job_dispatch is the biggest consumer of this, and it was doing the incorrect thing to begin with.

Thus, after this change, we won't be able to know which komodo release this komodoenv was based on as easily, however, this might be fine. There are other ways to tell (read the generated komodoenv.conf)

Then, if KOMODO_RELEASE doesn't have a /, it's a vanilla komodo release from /prog/res/komodo. If KOMODO_RELEASE is an absolute path (contains a / as its first character), then it's the path to a komodoenv. Otherwise, relative paths make no sense here.