From f8fe25134444131f3e0b8b4a0e1d914423506737 Mon Sep 17 00:00:00 2001 From: alexPatrie Date: Mon, 26 Feb 2024 15:18:07 -0500 Subject: [PATCH] updated dockerfile for chmod and copasi process --- Dockerfile | 6 ++++-- biosimulator_processes/copasi_process.py | 16 +++++++++++++++- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 223d6eb55..652a5ebe4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -77,8 +77,8 @@ # # CMD ["poetry", "run", "jupyter", "lab", "--ip=0.0.0.0", "--port=8888", "--no-browser", "--allow-root"] -# Use a more specific tag instead of latest for reproducibility -FROM ubuntu:20.04 +# TODO: Use a more specific tag instead of latest for reproducibility +FROM ubuntu:latest ENV DEBIAN_FRONTEND=noninteractive \ XVFB_RES="1920x1080x24" \ @@ -126,6 +126,8 @@ RUN useradd -m -s /bin/bash jupyteruser && chown -R jupyteruser:jupyteruser /app USER jupyteruser +RUN chmod +x /app/notebooks + VOLUME /app/data CMD ["poetry", "run", "jupyter", "lab", "--ip=0.0.0.0", "--port=8888", "--no-browser", "--allow-root"] diff --git a/biosimulator_processes/copasi_process.py b/biosimulator_processes/copasi_process.py index 1c931a8ce..cb00b6bb5 100644 --- a/biosimulator_processes/copasi_process.py +++ b/biosimulator_processes/copasi_process.py @@ -46,11 +46,25 @@ set_species, run_time_course, get_compartments, - model_info + model_info, + biomodels ) from process_bigraph import Process, Composite, pf +def find_models(term: str): + return biomodels.search_for_model(term) + + +def fetch_model(term: str, index: int = 0): + """Searrch for models matching the term and return an instantiated model from BioModels. + + TODO: Implement a dynamic search of this + """ + + + + class CopasiProcess(Process): config_schema = { 'model_file': 'string',