create ssl cer in container to serve content
This commit is contained in:
@@ -1,11 +1,20 @@
|
||||
FROM php:7.0-apache
|
||||
|
||||
RUN docker-php-ext-install pdo pdo_mysql mysqli
|
||||
RUN a2enmod rewrite
|
||||
RUN a2enmod rewrite ssl
|
||||
|
||||
COPY docker/php/apache2.conf /etc/apache2/
|
||||
COPY backend /var/www/html
|
||||
|
||||
COPY docker/apache/apache2.conf /etc/apache2/
|
||||
COPY docker/apache/default-ssl.conf /etc/apache2/sites-available/default-ssl.conf
|
||||
|
||||
COPY backend /var/www/html
|
||||
COPY docker/php/.htaccess /var/www/html/
|
||||
|
||||
RUN chown -R www-data:www-data /var/www/html
|
||||
RUN chown -R www-data:www-data /var/www/html
|
||||
|
||||
RUN openssl req -new -newkey rsa:2048 -days 365 -nodes -x509 \
|
||||
-subj "/C=BA/ST=FBiH/L=Sarajevo/O=Saburly/CN=localhost" \
|
||||
-keyout /etc/ssl/private/selfsigned.key -out /etc/ssl/certs/selfsigned.crt
|
||||
|
||||
WORKDIR /etc/apache2/sites-enabled
|
||||
RUN ln -s ../sites-available/default-ssl.conf default-ssl.conf
|
||||
Reference in New Issue
Block a user