From 8528d3fe8c29c9eab9eed56220f974f849743782 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?PICHOU=20Ky=C3=A2ne?= <kyane@kyane.fr>
Date: Mon, 19 Mar 2018 22:03:16 +0100
Subject: [PATCH] Fix etherpad encoding issue

---
 pica-etherpad/Dockerfile        | 6 +++---
 pica-etherpad/add/entrypoint.sh | 3 ++-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/pica-etherpad/Dockerfile b/pica-etherpad/Dockerfile
index adf650df..b7f9bfe9 100644
--- a/pica-etherpad/Dockerfile
+++ b/pica-etherpad/Dockerfile
@@ -7,7 +7,7 @@ ENV ETHERPAD_VERSION 1.6.1
 COPY add/entrypoint.sh /entrypoint.sh
 
 #Installation de NodeJS + NPM
-RUN useradd -d /opt/etherpad-lite -u 1000 etherpad && \ 
+RUN useradd -d /opt/etherpad-lite -u 1000 etherpad && \
     curl -sL https://deb.nodesource.com/setup_8.x | bash - && \
     apt-get update && \
     apt-get install -y nodejs unzip mysql-client  && \
@@ -15,11 +15,11 @@ RUN useradd -d /opt/etherpad-lite -u 1000 etherpad && \
     curl -SL https://github.com/ether/etherpad-lite/archive/${ETHERPAD_VERSION}.zip > etherpad.zip && \
     unzip etherpad && \
     rm -Rf etherpad.zip etherpad-lite-${ETHERPAD_VERSION}/.git && \
-    mv etherpad-lite-${ETHERPAD_VERSION} /opt/etherpad-lite && \ 
+    mv etherpad-lite-${ETHERPAD_VERSION} /opt/etherpad-lite && \
     chown -R etherpad: /opt/etherpad-lite && \
     chmod +x /entrypoint.sh
 
-USER etherpad 
+USER etherpad
 WORKDIR /opt/etherpad-lite
 
 #First starting of services
diff --git a/pica-etherpad/add/entrypoint.sh b/pica-etherpad/add/entrypoint.sh
index efe85178..f7b8f350 100644
--- a/pica-etherpad/add/entrypoint.sh
+++ b/pica-etherpad/add/entrypoint.sh
@@ -54,7 +54,8 @@ if [ ! -f settings.json ]; then
 			    "user"    : "${ETHERPAD_DB_USER}",
 			    "host"    : "${MYSQL_PORT_3306_TCP_ADDR}",
 			    "password": "${ETHERPAD_DB_PASSWORD}",
-			    "database": "${ETHERPAD_DB_NAME}"
+			    "database": "${ETHERPAD_DB_NAME}",
+			    "charset" : "utf8mb4"
 			  },
 	EOF
 
-- 
GitLab