Skip to content

Commit

Permalink
update base image to fix vulnerabilities
Browse files Browse the repository at this point in the history
  • Loading branch information
Maiykol committed Jul 22, 2024
1 parent 74f842e commit 062fcbe
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 83 deletions.
36 changes: 4 additions & 32 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM continuumio/miniconda3:4.10.3
FROM continuumio/miniconda3

WORKDIR /usr/src/caddie/

Expand All @@ -7,49 +7,21 @@ ENV PYTHONUNBUFFERED 1
ENV LC_ALL=C.UTF-8
ENV LANG=C.UTF-8

# install gcc
RUN apt-get update
RUN apt-get -y install build-essential
RUN apt-get -y install python-dev python3-dev
RUN apt-get -y install gcc

# RUN apt-get update
# RUN apt-get install -y supervisor nginx
# RUN apt-get install -y libgtk-3-dev
# RUN apt-get install -y wget


RUN conda install -y conda=4.10.3
RUN conda install -c conda-forge -y graph-tool

# setuptools 58 does not support use_2to3
# RUN pip install setuptools==57.5.0
# RUN pip install -r /usr/src/caddie/requirements.txt
# RUN pip install gunicorn




# OLD
RUN apt-get update
RUN apt-get install -y supervisor nginx
RUN apt-get install -y libgtk-3-dev
RUN apt-get install wget

COPY ./requirements.txt /usr/src/caddie/requirements.txt

# RUN conda install -y conda=4.3.16
# RUN conda install -c conda-forge -y graph-tool=2.32

RUN pip install -r /usr/src/caddie/requirements.txt
RUN pip install gunicorn






# RUN pyensembl install --release 106 --species human
# RUN pip3 install setuptools==57
RUN pip3 install -r /usr/src/caddie/requirements.txt
RUN pip3 install gunicorn

COPY ./supervisord.conf /etc/supervisor/conf.d/supervisord.conf
COPY ./docker-entrypoint.sh /entrypoint.sh
Expand Down
9 changes: 5 additions & 4 deletions caddie/utils/vcfUtils.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import vcf # VCF 4.1, 4-2
# import vcf # VCF 4.1, 4-2
# import vcfpy # VCF 4.3
import vap
# import vap
from sqlalchemy import create_engine


Expand All @@ -12,7 +12,7 @@ def __read_pyvcf(file):
:param file:
:return: vcf reader object
"""
return vcf.Reader(fsock=file)
# return vcf.Reader(fsock=file)

@staticmethod
def __annotate(vcf_reader):
Expand All @@ -32,7 +32,8 @@ def __annotate(vcf_reader):
annotations = []
for record in vcf_reader:
for alt in record.ALT:
annotation = vap.annotate_variant(conn, f'chr{record.CHROM}', record.POS, record.REF, alt)
# annotation = vap.annotate_variant(conn, f'chr{record.CHROM}', record.POS, record.REF, alt)
annotation = None
if annotation is not None:
annotations.append((record, annotation))
return annotations
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ services:
- db
- redis
db:
image: postgres
image: postgres:15
restart: always
hostname: db
networks:
Expand Down
53 changes: 7 additions & 46 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,69 +19,30 @@ flake8-quotes==3.0.0
gunicorn==20.1.0
mccabe==0.6.1
networkx==2.5
pandas==1.1.5
psycopg2-binary==2.9.6
numpy==1.26.4
pandas==1.3.5
psycopg2-binary
# pycairo==1.20.1
pycodestyle==2.5.0
# pycosat==0.6.3
pyflakes==2.1.1
# PyGObject==3.40.1
# pyparsing==2.4.7
pysam==0.21.0
pysam
python-dateutil==2.8.1
pytz==2019.3
PyVCF==0.6.8
# PyVCF==0.6.8
redis==3.4.1
rq==1.3.0
six==1.15.0
SQLAlchemy==1.3.23
sqlparse==0.3.1
urllib3==1.25.10
vcf-annotate-polyphen==0.1.2
vcfpy==0.13.3

# vcf-annotate-polyphen
# vcfpy
# pysam==0.21.0
deepmerge==0.3.0
# pyensembl==2.0.0
#domino-python==0.1.1



# asgiref==3.2.7
# certifi==2020.6.20
# chardet==3.0.4
# click==7.1.2
# decorator==4.4.2
# Django==3.0.5
# django-cors-headers==3.4.0
# django-redis==4.11.0
# django-rq-dashboard==0.3.3
# djangorestframework==3.11.0
# djangorestframework-camel-case==1.1.2
# entrypoints==0.3
# flake8==3.7.9
# flake8-quotes==3.0.0
# idna==2.10
# mccabe==0.6.1
# networkx==2.4
# numpy==1.19.5
# pandas==1.1.5
# psycopg2-binary==2.9.6
# pycodestyle==2.5.0
# pyflakes==2.1.1
# python-dateutil==2.8.2
# pytz==2020.1
# redis==3.4.1
# requests
# rq==1.3.0
# six==1.15.0
# sqlparse==0.3.1
# urllib3==1.25.10
# pyvcf==0.6.8
# sqlalchemy==1.3.23
# vcf-annotate-polyphen==0.1.2
# vcfpy==0.13.3
# pysam==0.21.0
# deepmerge==0.3.0
# # pyensembl==2.0.0
# #domino-python==0.1.1

0 comments on commit 062fcbe

Please sign in to comment.