I'm dockerizing our current old app. We use several services but the one I have issues on is the php, apache, and specifically the https for apache. I am using "php:5.6.30-apache" image, so I have php and apache pre-installed.
Now I changed the "000-default.conf" with this content:
<VirtualHost *:80>
ServerAdmin admin@admin.io
DocumentRoot /var/www/html/app/htdocsAdmin
ServerName admin.local.app.io
CustomLog /var/log/apache2/app.admin.access.log "trueip_combined"
ErrorLog /var/log/apache2/app.admin.error.log
<Directory /var/www/html/app/htdocsAdmin>
AllowOverride Options FileInfo AuthConfig
Require all granted
</Directory>
</VirtualHost>
This is my docker file:
FROM php:5.6.30-apache
MAINTAINER Tzook Bar Noy
ADD default /etc/apache2/sites-available/000-default.conf
RUN apt-get update \
&& apt-get install -y apt-utils \
&& apt-get install -y php5-dev php5-memcached \
&& apt-get install -y memcached
RUN apt-get update && apt-get install -y apt-utils
RUN apt-get install -y libz-dev libmemcached-dev
RUN pecl install memcached-2.2.0
RUN echo extension=memcached.so >> /usr/local/etc/php/conf.d/memcached.ini
RUN a2enmod rewrite
RUN a2enmod ssl
EXPOSE 80
EXPOSE 443
Don't mind the memcached stuff, just see that I enable "ssl" and expose ports 80,443
This is being ran with docker-compose:
php:
build:
context: ./php
dockerfile: Dockerfile
ports:
- "80:80"
- "443:443"
volumes:
- ./../../:/var/www/html
networks:
- appnet
tty: true
but after all of that, I still get this from chrome:
"ERR_SSL_PROTOCOL_ERROR"