Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate off Anaconda to Poetry and create dedicated RMG-Py builder image #165

Draft
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

DarkAce65
Copy link

@DarkAce65 DarkAce65 commented Feb 24, 2021

This PR migrates the base application off of Anaconda and onto poetry. It does this by creating a new image dedicated to building RMG-Py from source and copies the resulting binaries into application container via a Docker multi-stage build (Docker docs).

Another couple things to note:

  • Drops the docker-compose file version from 3.8 -> 3.7 for compatibility with older Docker Engine versions
  • Cleans up the docker-compose files to sort sections and simplify paths

Note that I wasn't able to run the application since I don't have access to RMG-Models - @kianmehrabani you'll have to verify this (and fix a couple other things like the README, keys, deployment, etc. 😄)

Resolves #166.

@kiancm kiancm self-requested a review February 24, 2021 05:05
@kiancm kiancm closed this Feb 24, 2021
@kiancm kiancm reopened this Feb 24, 2021
Dockerfile Outdated
@@ -1,11 +1,26 @@
FROM ghcr.io/comocheng/kineticmodelssite/kms-build:latest
# Fetch RMG-Py build
FROM comocheng/kms-rmgpy:latest as rmgpy
Copy link
Author

Choose a reason for hiding this comment

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

comocheng/kms-rmgpy doesn't exist yet - this should be where the Dockerfile.rmg image should be built to

RUN apk add --no-cache curl \
&& (curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python -)
ENV PATH="$POETRY_HOME/bin:$PATH" \
PYTHONPATH="/rmgpy:$PYTHONPATH"
Copy link
Author

Choose a reason for hiding this comment

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

Note that RMG-Py is not specified as a dependency in the pyproject.toml - the dependency is added to the PYTHONPATH here

volumes:
rmg-models:
external: true
conda:
Copy link
Author

Choose a reason for hiding this comment

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

This volume should no longer be necessary

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dockerize rmg binary installation so we can use poetry for dependency management
2 participants