-
Notifications
You must be signed in to change notification settings - Fork 125
/
Dockerfile
26 lines (20 loc) · 1.1 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
FROM python:3.10-slim
LABEL maintainer="Charlie Lewis <[email protected]>"
LABEL poseidon.namespace="primary"
ENV PYTHONUNBUFFERED 1
COPY . /poseidon
WORKDIR /poseidon
ENV PATH="${PATH}:/root/.local/bin"
RUN apt-get update && apt-get install -y --no-install-recommends curl gcc git g++ libev-dev libyaml-dev tini && \
curl -sSL https://install.python-poetry.org | python3 - --version 1.4.2 && \
poetry config virtualenvs.create false && \
cd lib/poseidon_api && poetry install --no-interaction --no-ansi && poetry build && cd ../../ && \
cd lib/poseidon_cli && poetry install --no-interaction --no-ansi && poetry build && cd ../../ && \
cd lib/poseidon_core && poetry install --no-interaction --no-ansi && poetry build && cd ../../ && \
apt-get purge -y gcc g++ && apt -y autoremove --purge && rm -rf /var/cache/* /root/.cache/*
HEALTHCHECK --interval=15s --timeout=15s \
CMD curl --silent --fail http://localhost:9304/ || exit 1
RUN mkdir -p /opt/poseidon
RUN mv /poseidon/config/poseidon.config /opt/poseidon/poseidon.config
ENV POSEIDON_CONFIG /opt/poseidon/poseidon.config
CMD tini -s -- poseidon-core