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

Update Dockerfile #125

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
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
4 changes: 3 additions & 1 deletion Docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ RUN apt-get update && \
RUN curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash
RUN apt-get install -y git-lfs

RUN git clone https://github.com/RabadanLab/arcasHLA.git
RUN git clone --branch VergaJU-patch-1 https://github.com/VergaJU/arcasHLA.git
RUN conda env create -f /app/arcasHLA/environment.yml
RUN echo "source activate arcas-hla" > ~/.bashrc
ENV PATH /opt/conda/envs/arcas-hla/bin:$PATH
ENV PATH=/app/arcasHLA/:$PATH
RUN arcasHLA reference --update
15 changes: 13 additions & 2 deletions scripts/reference.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,20 @@ def check_ref():
build_fasta()

def fetch_hla_dat():
'''Clones IMGTHLA github to database.'''
'''Clones IMGTHLA github to database. Git lfs pull to be sure to download all needed files'''

if isdir(IMGTHLA):
run_command(['rm', '-rf', IMGTHLA])

command = ['git', 'clone', IMGTHLA_git, IMGTHLA]
run_command(command,
'[reference] Cloning IMGT/HLA database:')


## run git lfs pull
command = ['git', '-C', IMGTHLA, "lfs", "pull"]
run_command(command,
'[reference] pull large files')

def checkout_version(commithash, verbose = True):
'''Checks out a specific IMGTHLA github version given a commithash.'''

Expand All @@ -105,6 +110,12 @@ def checkout_version(commithash, verbose = True):
run_command(command, '[reference] Checking out IMGT/HLA:')
else:
run_command(command)

## run git lfs pull
command = ['git', '-C', IMGTHLA, "lfs", "pull"]
run_command(command,
'[reference] pull large files')


def hla_dat_version(print_version = False):
'''Returns commithash of downloaded IMGTHLA database.'''
Expand Down