Browse Source

fix permissions on db file

Stefan Stidl 1 năm trước cách đây
mục cha
commit
c00ad26abe
1 tập tin đã thay đổi với 6 bổ sung2 xóa
  1. 6 2
      docker/entrypoint.sh

+ 6 - 2
docker/entrypoint.sh

@@ -18,9 +18,13 @@ cp /speedtest/favicon.ico /var/www/html/
 
 
 # Set custom webroot on alpine
 # Set custom webroot on alpine
 if is_alpine; then
 if is_alpine; then
+  echo "ALPINE IMAGE"
   sed -i "s#\"/var/www/localhost/htdocs\"#\"/var/www/html\"#g" /etc/apache2/httpd.conf
   sed -i "s#\"/var/www/localhost/htdocs\"#\"/var/www/html\"#g" /etc/apache2/httpd.conf
+else
+  echo "DEBIAN IMAGE"
 fi
 fi
 
 
+
 # Set up backend side for standlone modes
 # Set up backend side for standlone modes
 if [[ "$MODE" == "standalone" || "$MODE" == "dual" ]]; then
 if [[ "$MODE" == "standalone" || "$MODE" == "dual" ]]; then
   cp -r /speedtest/backend/ /var/www/html/backend
   cp -r /speedtest/backend/ /var/www/html/backend
@@ -82,9 +86,9 @@ if [[ "$TELEMETRY" == "true" && ("$MODE" == "frontend" || "$MODE" == "standalone
 
 
   mkdir -p /database/
   mkdir -p /database/
   if is_alpine; then
   if is_alpine; then
-    chown apache /database/
+    chown -R apache /database/
   else
   else
-    chown www-data /database/
+    chown -R www-data /database/
   fi
   fi
 fi
 fi