summaryrefslogtreecommitdiffstats
path: root/Dockerfile
diff options
context:
space:
mode:
authorDaniel Baumann <mail@daniel-baumann.ch>2023-11-04 18:52:12 +0000
committerDaniel Baumann <mail@daniel-baumann.ch>2023-11-04 18:52:12 +0000
commita596894f2d782b9df54c026696e55da1267f7936 (patch)
treee2696ad38feb91700ac875966e6aa0b30e732566 /Dockerfile
parentAdding upstream version 1.13.1. (diff)
downloadiredis-a596894f2d782b9df54c026696e55da1267f7936.tar.xz
iredis-a596894f2d782b9df54c026696e55da1267f7936.zip
Adding upstream version 1.14.0.upstream/1.14.0
Signed-off-by: Daniel Baumann <mail@daniel-baumann.ch>
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile28
1 files changed, 13 insertions, 15 deletions
diff --git a/Dockerfile b/Dockerfile
index 99c0463..a0baf16 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,18 +1,16 @@
-FROM python:3
+FROM redis/redis-stack-server:latest
-WORKDIR /iredis
-COPY README.md poetry.lock pyproject.toml ./
-COPY iredis ./iredis
-
-RUN apt-get update && apt-get install -y --allow-unauthenticated \
- redis-server && \
- rm -rf /var/lib/apt/lists/*
+COPY . /iredis
+RUN apt-get update --fix-missing
+RUN apt-get install -yqq python3 python3-pip python-is-python3
+RUN python3 -m pip install poetry
+WORKDIR /iredis
+RUN poetry config virtualenvs.create false
+RUN poetry build
+RUN pip install dist/iredis*.tar.gz
+WORKDIR /
+RUN rm -rf .cache /var/cache/apt
+RUN rm -rf /iredis
-RUN python3 -m venv iredis_env && \
- . iredis_env/bin/activate && \
- pip install poetry && \
- poetry install --no-dev && \
- rm -rf ~/.cache
-
-CMD ["sh","-c","redis-server --daemonize yes && . iredis_env/bin/activate && iredis"]
+CMD ["sh", "-c", "/opt/redis-stack/bin/redis-stack-server --daemonize yes && iredis"]