# Use an official PHP image with Apache FROM php:5.6-apache # Enable Apache mod_rewrite if needed RUN a2enmod rewrite # Install PHP extensions if needed RUN docker-php-ext-install pdo pdo_mysql mbstring mysqli # Set the working directory WORKDIR /var/www/html # Copy your PHP project to the container COPY . /var/www/html # Set permissions for the Apache user RUN chown -R www-data:www-data /var/www/html RUN chmod -R 755 /var/www/html # Expose port 80 EXPOSE 80