FROM ubuntu:22.04 ARG DEBIAN_FRONTEND=noninteractive RUN apt-get update RUN apt-get install -y apt-transport-https RUN apt-get install -y software-properties-common RUN add-apt-repository -y ppa:ondrej/php RUN add-apt-repository -y ppa:ondrej/apache2 RUN apt-get update RUN apt-get install --no-install-recommends -y mariadb-server apache2 libapache2-mod-php8.3 php8.3-apcu php8.3-curl php8.3-mysql php8.3-zip unzip RUN apt-get install curl RUN chown -R www-data: /var/www RUN a2enmod headers rewrite RUN a2enmod proxy_fcgi setenvif RUN echo "ServerName localhost" | tee /etc/apache2/conf-available/fqdn.conf && a2enconf fqdn.conf RUN echo '' > /etc/apache2/conf-available/allowoverride.conf && \ echo ' AllowOverride All' >> /etc/apache2/conf-available/allowoverride.conf && \ echo '' >> /etc/apache2/conf-available/allowoverride.conf && \ a2enconf allowoverride # Start Apache service CMD ["apachectl", "-D", "FOREGROUND"]