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

Strategus in Broadsea #110

Open
alondhe opened this issue Oct 21, 2023 · 4 comments
Open

Strategus in Broadsea #110

alondhe opened this issue Oct 21, 2023 · 4 comments

Comments

@alondhe
Copy link
Collaborator

alondhe commented Oct 21, 2023

OHDSI/Strategus#97

@anthonysena
Copy link

Just wanted to make a note about running Strategus on Broadsea since I've spent some time to get this working and wanted to get some feedback on how to potentially share this work with the community.

Some notes on what I've done thus far:

  • I had to add a few system libraries to get Strategus to work. Specifically: libsecret-1-0, libsodium23, libxml2, libglpk-dev. I think these could be added to the Broadsea-Hades Dockerfile here.
  • Install Strategus remotes::install_github("OHDSI/Strategus", ref="develop") (using develop as it can now detect module instantiation problems)
  • Using RStudio on the Broadsea HADES container, I was then able to run the Execute Strategus on Eunomia. I think this could be done via the Dockerfile by doing some thing like this:
ENV INSTATIATED_MODULES_FOLDER="/home/ohdsi/strategus/modules"
RUN R <<EOF
    ... Contents of the Execute Strategus on Eunomia go here ...
EOF

We may be able to just run Strategus::ensureAllModulesInstantiated with the test analysisSpecification bundled with Strategus but thought running the full study may be better to verify the setup is complete and in good working order.

Questions

  1. Do we want to include Strategus in the Broadsea-Hades container by default or do we want to consider another container that is specifically for running Strategus? Reason I ask: the installation of Strategus and the respective modules is driven by the analysis specification for the study. So, having a container with Strategus installed could be considered the "base" image. To have a complete container for a study, you'd also want to bundle the modules needed for that study (which are detailed in the study analysis specification JSON) in the container so that the download includes everything required. I'm not sure of the best way to layer this together using Docker.
  2. Do we want to modify Broadsea-Hades to include the system libraries mentioned above? I think this would help since I hit issues when installing packages such as keyring, xml2 and when using SqlLite which are all core packages at the moment.
  3. Do we want to automatically include RStudio as part of the container? Perhaps that can be optionally installed/used where necessary?

Tagging @leeevans for awareness and input.

@haydenbspence
Copy link
Contributor

I wonder if using a multi-stage build would be a way to handle the libsecret-1-0, libsodium23, libxml2, libglpk-dev dependencies. Are they needed in building or are they continually used by Strategus @anthonysena?

@anthonysena
Copy link

I wonder if using a multi-stage build would be a way to handle the libsecret-1-0, libsodium23, libxml2, libglpk-dev dependencies. Are they needed in building or are they continually used by Strategus @anthonysena?

At the moment, these are used by Strategus when executing. The reason for this is that each module in Strategus will use the keyring package to access a secure store with credentials. We're considering the elimination of using keyring in Strategus to simplify things and to eliminate these types of OS dependencies.

@haydenbspence
Copy link
Contributor

I wonder if using a multi-stage build would be a way to handle the libsecret-1-0, libsodium23, libxml2, libglpk-dev dependencies. Are they needed in building or are they continually used by Strategus @anthonysena?

At the moment, these are used by Strategus when executing. The reason for this is that each module in Strategus will use the keyring package to access a secure store with credentials. We're considering the elimination of using keyring in Strategus to simplify things and to eliminate these types of OS dependencies.

r-wasm has a multi-stage build approach with keyring that may be worth checking out. The foundational (building) image is flang-wasm Dockerfile which includes Ubuntu and dependencies. That image is then referenced by the webr Dockerfile which is finally cleaned and layers squashed.

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

No branches or pull requests

3 participants