Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Docker Build Test

on:
push:
branches:
master
pull_request:
branches:
master
schedule:
- cron: '0 0 * * 1'

jobs:
build-test:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: [3.8]
# TODO: We probably should switch to using the Docker version.
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Build Docker
run: |
cd basic && docker build .
7 changes: 4 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
FROM continuumio/miniconda3:4.8.2
FROM continuumio/miniconda3:4.10.3
MAINTAINER Mingxun Wang "[email protected]"

WORKDIR /app
RUN apt-get update -y && \
apt-get install -y libxrender-dev && \
apt-get install -y git-core
RUN conda create -y -n usi -c conda-forge -c bioconda -c defaults celery \
RUN conda install -c conda-forge mamba
RUN mamba create -y -n usi -c conda-forge -c bioconda -c defaults celery \
dash=1.20.0 dash-bootstrap-components=0.9.2 flask gunicorn \
joblib matplotlib numba numpy openssl qrcode rdkit requests \
requests-cache scipy spectrum_utils werkzeug
requests-cache scipy spectrum_utils==0.3.5 werkzeug==2.0.0
RUN /bin/bash -c 'source activate usi && pip install "git+https://github.com/berlinguyinca/spectra-hash.git#subdirectory=python" && pip install celery-once'

RUN echo "source activate usi" > ~/.bashrc
Expand Down
12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,19 @@ clear-cache:

#Docker Compose
server-compose-interactive:
docker-compose build
docker-compose up
docker-compose --compatibility build
docker-compose --compatibility up

server-compose:
docker-compose build
docker-compose up -d
docker-compose --compatibility build
docker-compose --compatibility up -d

server-compose-production-interactive:
docker-compose build
docker-compose --compatibility build
docker-compose -f docker-compose.yml -f docker-compose-production.yml --compatibility up

server-compose-production:
docker-compose build
docker-compose --compatibility build
docker-compose -f docker-compose.yml -f docker-compose-production.yml --compatibility up -d

attach:
Expand Down
8 changes: 5 additions & 3 deletions docker-compose-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@ services:
- default
- nginx-net
environment:
VIRTUAL_HOST: metabolomics-usi.ucsd.edu,metabolomics-usi.gnps2.org
VIRTUAL_PORT: 5087
LETSENCRYPT_HOST: metabolomics-usi.ucsd.edu,metabolomics-usi.gnps2.org
#VIRTUAL_HOST: metabolomics-usi.ucsd.edu,metabolomics-usi.gnps2.org
VIRTUAL_HOST: metabolomics-usi.gnps2.org
VIRTUAL_PORT: 5000
#LETSENCRYPT_HOST: metabolomics-usi.ucsd.edu,metabolomics-usi.gnps2.org
LETSENCRYPT_HOST: metabolomics-usi.gnps2.org
LETSENCRYPT_EMAIL: [email protected]
command: /app/run_server.sh
deploy:
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ requests
requests_cache
scipy
spectrum_utils
werkzeug
git+https://github.com/berlinguyinca/spectra-hash.git#subdirectory=python
werkzeug==2.0.0
git+https://github.com/berlinguyinca/spectra-hash.git#subdirectory=python