# Extend the official PHP image
FROM php:apache

# Install the mysqli extension
RUN docker-php-ext-install mysqli
RUN a2enmod ssl
RUN service apache2 restart
COPY ./cyberhex-code /var/www/html
RUN mkdir -p /var/www/html/install/
RUN mkdir -p /var/www/html/database_srv
RUN mkdir -p /var/www/html/export
RUN mkdir -p /var/www/html/import
RUN chown -R www-data:www-data /var/www/html/export/
RUN chown -R www-data:www-data /var/www/html/import/
RUN chown -R www-data:www-data /var/www/html/install/
RUN chown -R www-data:www-data /var/www/html/database_srv/