Skip to content

Clarify docker compose file for plugin developers#83

Merged
CasperWA merged 8 commits intomasterfrom
cwa/close-82-oteapi-dev-image
Mar 14, 2022
Merged

Clarify docker compose file for plugin developers#83
CasperWA merged 8 commits intomasterfrom
cwa/close-82-oteapi-dev-image

Conversation

@CasperWA
Copy link
Copy Markdown
Contributor

Fixes #82

@CasperWA CasperWA requested a review from jesper-friis March 11, 2022 10:21
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Mar 11, 2022

Codecov Report

Merging #83 (c8eb0fc) into master (2b33b2f) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #83   +/-   ##
=======================================
  Coverage   68.11%   68.11%           
=======================================
  Files          15       15           
  Lines         414      414           
=======================================
  Hits          282      282           
  Misses        132      132           
Flag Coverage Δ
pytest 68.11% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2b33b2f...c8eb0fc. Read the comment docs.

@CasperWA CasperWA added the BLOCKING This issue or PR blocks further development label Mar 11, 2022
Comment thread Dockerfile
EXPOSE 8080
CMD if [ "${PATH_TO_OTEAPI_CORE}" != "/dev/null" ] && [ -n "${PATH_TO_OTEAPI_CORE}" ]; then \
pip install -U --force-reinstall -c requirements.txt -e /oteapi_core; fi \
pip install -U --force-reinstall -e /oteapi_core; fi \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is requirements removed?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's removed as a constraint for the installation of oteapi-core. This is to avoid the installation failing, should the local version of oteapi-core differ from the one listed in requirements.txt.
Essentially, keeping the -c command here defeats the purpose of installing a local version of oteapi-core. I.e., this was really a bug.

Comment thread README.md
- otenet
volumes:
- "${PATH_TO_OTEAPI_CORE:-/dev/null}:/oteapi-core"
- "${PATH_TO_OTEAPI_ANOTHER_PLUGIN:-/dev/null}:/oteapi-another-plugin"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One might depend on more than one additional plugin. Wouldn't it be smarter with a single environment variable with a (e.g. colon-separated) list of plugin paths? Something like:

OTEAPI_PLUGIN_PATH="/path/to/first/plugin:/path/to/second/plugin"

Is there any reason to treat oteapi-core from other plugins with regard to this?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OTEAPI Core is special, since it's already a core dependency of the service and is therefore set up differently within the Dockerfile.
Concerning other plugins, I don't expect anyone to install more than 1-2 external plugins to develop, other than the one they're already developing.

Comment thread README.md
Copy link
Copy Markdown
Contributor

@jesper-friis jesper-friis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved when the typo is fixed.

The suggestion about replacing PATH_TO_OTEAPI_CORE and `` PATH_TO_OTEAPI_ANOTHER_PLUGIN with e.g. OTEAPI_PLUGIN_PATH can be a separate issue.

@CasperWA CasperWA enabled auto-merge (squash) March 14, 2022 09:20
@CasperWA CasperWA merged commit f978e32 into master Mar 14, 2022
@CasperWA CasperWA deleted the cwa/close-82-oteapi-dev-image branch March 14, 2022 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BLOCKING This issue or PR blocks further development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clarify how to install local oteapi-core for plugin development

3 participants