-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDockerfile
More file actions
55 lines (44 loc) · 1.42 KB
/
Dockerfile
File metadata and controls
55 lines (44 loc) · 1.42 KB
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
FROM python:3.12-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
cmake \
pkg-config \
git \
wget \
gnupg \
lsb-release \
ca-certificates \
mmseqs2
# Install PostgreSQL client 16
RUN apt-get update && \
apt-get install -y wget gnupg lsb-release && \
sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' && \
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor -o /etc/apt/trusted.gpg.d/postgres.gpg && \
apt-get update && \
apt-get install -y postgresql-client-16 && \
rm -rf /var/lib/apt/lists/*
# Install Poetry
ENV POETRY_VERSION=1.8.2
RUN pip install "poetry==$POETRY_VERSION"
# Set working directory
export WORKDIR=\$RUN_DIR
singularity exec --nv \\
--bind \$RUN_DIR:\$RUN_DIR \\
--bind \$PWD/fantasia:\$PWD/fantasia \\
--bind \$PWD:\$PWD \\
\$FT_IMG fantasia initialize --config \$CFG
singularity exec --nv \\
--bind \$RUN_DIR:\$RUN_DIR \\
--bind \$PWD/fantasia:\$PWD/fantasia \\
--bind \$PWD:\$PWD \\
\$FT_IMG fantasia run --config \$CFG
# Copy project metadata
COPY pyproject.toml ./
# Primero copia
COPY . .
# Luego instala
RUN poetry config virtualenvs.create false \
&& poetry install --no-dev \
&& rm -rf /root/.cache/pypoetry ...
# Default command
ENTRYPOINT ["fantasia"]