Skip to content

Commit 0fcb925

Browse files
committed
add docker, requirements and docs
1 parent 4bc1099 commit 0fcb925

7 files changed

Lines changed: 16 additions & 5 deletions

File tree

.github/workflows/build-windows-executable-app.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,9 @@ jobs:
259259
260260
- name: Create .bat file
261261
run: |
262-
echo " start /min .\python-${{ env.PYTHON_VERSION }}\python -m streamlit run app.py local" > ${{ env.APP_NAME }}.bat
262+
echo "start /min .\python-${{ env.PYTHON_VERSION }}\python -m redis-server" > ${{ env.APP_NAME }}.bat
263+
echo "start /min .\python-${{ env.PYTHON_VERSION }}\python -m rq worker --with-scheduler" >> ${{ env.APP_NAME }}.bat
264+
echo "start /min .\python-${{ env.PYTHON_VERSION }}\python -m streamlit run app.py local" >> ${{ env.APP_NAME }}.bat
263265
264266
- name: Create All-in-one executable folder
265267
run: |

Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,8 @@ RUN echo "0 3 * * * /root/miniforge3/envs/streamlit-env/bin/python /app/clean-up
141141
RUN echo "#!/bin/bash" > /app/entrypoint.sh && \
142142
echo "source /root/miniforge3/bin/activate streamlit-env" >> /app/entrypoint.sh && \
143143
echo "service cron start" >> /app/entrypoint.sh && \
144+
echo "redis-server" >> /app/entrypoint.sh && \
145+
echo "rq worker --with-scheduler" >> /app/entrypoint.sh && \
144146
echo "streamlit run app.py" >> /app/entrypoint.sh
145147
# make the script executable
146148
RUN chmod +x /app/entrypoint.sh

Dockerfile_simple

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ RUN echo "0 3 * * * /root/miniforge3/envs/streamlit-env/bin/python /app/clean-up
8787
RUN echo "#!/bin/bash" > /app/entrypoint.sh
8888
RUN echo "source /root/miniforge3/bin/activate streamlit-env" >> /app/entrypoint.sh && \
8989
echo "service cron start" >> /app/entrypoint.sh && \
90+
echo "redis-server" >> /app/entrypoint.sh && \
91+
echo "rq worker --with-scheduler" >> /app/entrypoint.sh && \
9092
echo "streamlit run app.py" >> /app/entrypoint.sh
9193
# make the script executable
9294
RUN chmod +x /app/entrypoint.sh

docs/installation.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,9 @@ Create and activate the conda environment:
4343

4444
Run the app via streamlit command in the terminal. *local* and *online* mode can be toggled in the settings.json. Learn more about *local* and *online* mode in the documentation page 📖 **OpenMS Template App**.
4545

46-
`streamlit run app.py`
46+
1. Open a new terminal and run `redis-server`
47+
2. On another terminal run `rq worker --with-scheduler` (multiple workers can be spawned)
48+
3. Finally start the application `streamlit run app.py`
4749

4850
## Docker
4951

environment.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,6 @@ dependencies:
1515
- captcha==0.5.0
1616
- pyopenms_viz==1.0.0
1717
- streamlit-js-eval
18-
- psutil==7.0.0
18+
- psutil==7.0.0
19+
- redis==5.2.1
20+
- rq==2.1.0

requirements.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,6 @@ plotly==5.22.0
88
captcha==0.5.0
99
pyopenms_viz==1.0.0
1010
streamlit-js-eval
11-
psutil==7.0.0
11+
psutil==7.0.0
12+
redis==5.2.1
13+
rq==2.1.0

test_gui.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
from pathlib import Path
66
import shutil
77

8-
98
@pytest.fixture
109
def launch(request):
1110
test = AppTest.from_file(request.param)

0 commit comments

Comments
 (0)