]> git.parisson.com Git - teleforma.git/commitdiff
Added redis for chat/notification
authorGael Le Mignot <gael@pilotsystems.net>
Mon, 7 Jun 2021 08:15:26 +0000 (10:15 +0200)
committerGael Le Mignot <gael@pilotsystems.net>
Mon, 7 Jun 2021 08:15:26 +0000 (10:15 +0200)
Dockerfile
app/bin/wait.sh
docker-compose.yml
requirements.txt

index e100361b814ad09918b1475bf186ecd8ce776458..0ed62a73393399ab87211b089971fcffd659220c 100644 (file)
@@ -46,9 +46,8 @@ RUN pip3 install -r requirements.txt
 
 COPY requirements-dev.txt /srv
 ARG dev=0
-RUN echo "${dev}"
 RUN if [ "${dev}" = "1" ]; then pip3 install -r requirements-dev.txt; fi
-RUN if [ "${dev}" = "1" ]; then apt-get -y install less nano postgresql-client; fi
+RUN if [ "${dev}" = "1" ]; then apt-get -y install less nano postgresql-client redis-tools; fi
 
 COPY lib /srv/lib
 COPY bin/build/local/setup_lib.sh /srv
index 0d92f08c5c2b28d70552d806f3120ff99d3e7a68..e4c94500e5c697187d84976f8520bc375488d6ad 100755 (executable)
@@ -1,3 +1,4 @@
 #!/bin/sh
 
 /srv/bin/misc/wait-for-it/wait-for-it.sh -h $DB_HOST -p $DB_PORT;
+/srv/bin/misc/wait-for-it/wait-for-it.sh -h redis -p 6379;
index 1286bc5d866bb6ebd5a4b118704fe4513d94c501..c80c38a1c595042ff36b25630b0a8dbd0d5060a3 100644 (file)
@@ -42,6 +42,14 @@ services:
           - -I 128m
           - -v
 
+  redis:
+    image: redis
+    entrypoint:
+      - redis-server
+      - --appendonly yes
+    volumes:
+      - ./var/redis:/data
+
 volumes:
     app:
     db:
index d026cc76b99fb14a135b47b6736556d01423ca1e..46a3f9b56d1d7794a86dd89bfba979afea313448 100644 (file)
@@ -25,3 +25,4 @@ weasyprint==52.5
 xlrd==2.0.1
 xlwt==1.3.0
 psycopg2==2.8.6 
+redis==3.5.3