Skip to content

Commit 4eb2d25

Browse files
committed
Update docker compose files
1 parent e86acc4 commit 4eb2d25

File tree

3 files changed

+14
-15
lines changed

3 files changed

+14
-15
lines changed

docker-compose.dev.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ services:
2929
command: docker/web/celery/worker/run.sh
3030

3131
ganache:
32-
image: trufflesuite/ganache-cli
33-
command: -d --defaultBalanceEther 10000 --gasLimit 10000000 -a 30 --chain.chainId 1337 --chain.networkId 1337
32+
image: trufflesuite/ganache:latest
33+
command: --defaultBalanceEther 10000 --gasLimit 10000000 -a 30 --chain.chainId 1337 --chain.networkId 1337 -d
3434
ports:
3535
- "8545:8545"

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ volumes:
55

66
services:
77
nginx:
8-
image: nginx:1.21-alpine
8+
image: nginx:1-alpine
99
hostname: nginx
1010
ports:
1111
- "8000:8000"
@@ -16,7 +16,7 @@ services:
1616
- web
1717

1818
redis:
19-
image: redis:5-alpine
19+
image: redis:7-alpine
2020
ports:
2121
- "6379:6379"
2222

docker/web/Dockerfile

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,24 @@
11
FROM python:3.10-slim
22

3-
ENV PYTHONUNBUFFERED 1
4-
WORKDIR /app
3+
ARG APP_HOME=/app
4+
WORKDIR ${APP_HOME}
5+
ENV PYTHONUNBUFFERED=1
56

6-
# Signal handling for PID1 https://github.com/krallin/tini
7-
ENV TINI_VERSION v0.19.0
8-
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
9-
RUN chmod +x /tini
7+
# https://eth-hash.readthedocs.io/en/latest/quickstart.html#specify-backend-by-environment-variable
8+
# `pysha3` is way faster than `pycryptodome` for CPython
9+
ENV ETH_HASH_BACKEND=pysha3
1010

1111
COPY requirements.txt ./
1212
RUN set -ex \
1313
&& buildDeps=" \
1414
build-essential \
15+
git \
1516
libssl-dev \
16-
libgmp-dev \
17-
pkg-config \
17+
libpq-dev \
1818
" \
1919
&& apt-get update \
20-
&& apt-get install -y --no-install-recommends $buildDeps \
20+
&& apt-get install -y --no-install-recommends $buildDeps tmux postgresql-client \
21+
&& pip install -U --no-cache-dir wheel setuptools pip \
2122
&& pip install --no-cache-dir -r requirements.txt \
2223
&& apt-get purge -y --auto-remove $buildDeps \
2324
&& rm -rf /var/lib/apt/lists/* \
@@ -28,5 +29,3 @@ RUN set -ex \
2829

2930
COPY . .
3031
RUN DJANGO_SETTINGS_MODULE=config.settings.local DJANGO_DOT_ENV_FILE=.env.local python manage.py collectstatic --noinput
31-
32-
ENTRYPOINT ["/tini", "--"]

0 commit comments

Comments
 (0)