combine all run commands

This commit is contained in:
Ruben Momoa
2024-08-20 15:10:49 +02:00
parent 6f648c4ebd
commit 40ad625556

View File

@@ -16,20 +16,20 @@ ENV NVM_DIR="/home/$USERNAME/.nvm"
COPY start-container.sh /usr/local/bin/start-container COPY start-container.sh /usr/local/bin/start-container
RUN apt-get -y update RUN apt-get -y update; \
RUN apt-get install -y curl git 7zip php php-xml php-curl php-xml php-mbstring php-mysql php-gd apt-get install -y curl git 7zip php php-xml php-curl php-xml php-mbstring php-mysql php-gd; \
RUN apt-get clean apt-get clean; \
RUN useradd --create-home --uid=${USER_UID} ${USERNAME} useradd --create-home --uid=${USER_UID} ${USERNAME}; \
RUN chmod +x /usr/local/bin/start-container chmod +x /usr/local/bin/start-container; \
RUN echo "install composer" echo "install composer"; \
RUN curl -o composer-setup.php https://getcomposer.org/installer curl -o composer-setup.php https://getcomposer.org/installer; \
RUN curl -o composer-setup.sig https://composer.github.io/installer.sig curl -o composer-setup.sig https://composer.github.io/installer.sig; \
RUN echo " composer-setup.php" >> composer-setup.sig echo " composer-setup.php" >> composer-setup.sig; \
RUN sha384sum -c composer-setup.sig sha384sum -c composer-setup.sig; \
RUN if [ -n "$COMPOSER_VERSION" ]; then COMPOSER_VERSION="--${COMPOSER_VERSION}"; fi if [ -n "$COMPOSER_VERSION" ]; then COMPOSER_VERSION="--${COMPOSER_VERSION}"; fi; \
RUN php composer-setup.php --install-dir=/usr/local/bin --filename=composer $COMPOSER_VERSION php composer-setup.php --install-dir=/usr/local/bin --filename=composer $COMPOSER_VERSION; \
RUN rm composer-setup.php composer-setup.sig /var/www/html/* rm composer-setup.php composer-setup.sig /var/www/html/*; \
RUN chown $USERNAME:$USERNAME /var/www/html chown $USERNAME:$USERNAME /var/www/html; \
EXPOSE 8080 EXPOSE 8080