forked from r-mllr/ecf_classify
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
58 lines (37 loc) · 1.58 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
FROM python:3.8-alpine as python
RUN apk update
RUN apk add --no-cache make automake gcc g++ subversion python3-dev python3
RUN mkdir /install
WORKDIR /install
COPY requirements.txt /requirements.txt
RUN pip3 install --prefix=/install -r /requirements.txt
FROM alpine:3.9 as builder
WORKDIR /src/
RUN apk add --no-cache gcc musl-dev make
RUN wget http://eddylab.org/software/hmmer/hmmer.tar.gz && tar zxf hmmer.tar.gz && cd hmmer-3.* && ./configure --prefix /src/ && make -j && make install
# This file is a template, and might need editing before it works on your project.
FROM ruby:2.6-alpine as ruby
# Edit with nodejs, mysql-client, postgresql-client, sqlite3, etc. for your needs.
# Or delete entirely if not needed.
#RUN apk --no-cache add nodejs postgresql-client tzdata
RUN apk add --no-cache --virtual build-deps build-base && \
apk add --no-cache git python3 && \
apk del build-deps
WORKDIR /usr/src/app
RUN gem install bundler
COPY .git .git
COPY . .
RUN bundle config set without 'development test'
RUN bundle install && rake -f Rakefile.prod install
FROM ruby:2.6-alpine
RUN apk add --no-cache --virtual build-deps build-base && \
apk add --no-cache python3 bash && \
apk del build-deps
COPY --from=ruby /usr/local/bundle /usr/local/bundle
COPY --from=builder /src/bin/hmm* /usr/bin/
COPY --from=python /install/lib/python3* /usr/local/lib/python3/
ENV PYTHONPATH=${PYTHONPATH}:/usr/local/lib/python3/site-packages/:/usr/local/lib/python3/
# Install build dependencies - required for gems with native dependencies
WORKDIR /
RUN ecf_classify download
CMD ["ecf_classify", "help"]