ksieren 2 anni fa
parent
commit
acf8f8c42d
1 ha cambiato i file con 5 aggiunte e 5 eliminazioni
  1. 5 5
      Dockerfile

+ 5 - 5
Dockerfile

@@ -33,13 +33,13 @@ RUN apt-get update && \
         zlib1g-dev && \
     rm -rf /var/lib/apt/lists/* /usr/src/* \
 
-COPY --from=composer /usr/bin/composer /usr/bin/composer
-
-# Switch to use a non-root user from here on
-#USER nobody
-
 # Add application
 WORKDIR /var/www/html
+RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer \
+RUN chown -R www-data:www-data /var/www/html
 
 # Expose the port apache is reachable on
 EXPOSE 80
+
+# Switch to use a non-root user from here on
+USER www-data