- moved ssl key generation into container
- mount html and webdav as volume
This commit is contained in:
+1
-10
@@ -6,18 +6,9 @@ RUN apt-get update && \
|
||||
apt-get install -y vim && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/ssl/private/localhost.key -out /etc/ssl/certs/localhost.crt -subj "/C=US/ST=YourState/L=YourCity/O=YourOrganization/CN=localhost"
|
||||
RUN htpasswd -nb davuser davuser > /var/www/.htpasswd
|
||||
|
||||
# Copy your PHP application into the default Apache document root
|
||||
COPY ./public-html/ /var/www/html/
|
||||
COPY ./webdav/ /var/www/webdav/
|
||||
|
||||
RUN chown -R root:www-data /var/www/
|
||||
|
||||
# Copy SSL certificate and key
|
||||
COPY ssl/localhost.crt /etc/ssl/certs/localhost.crt
|
||||
COPY ssl/localhost.key /etc/ssl/private/localhost.key
|
||||
|
||||
# Copy the custom Apache virtual host config
|
||||
COPY conf/my-httpd-vhosts.conf /etc/apache2/sites-available/my-ssl.conf
|
||||
COPY conf/webdav.conf /etc/apache2/sites-available/webdav.conf
|
||||
|
||||
Reference in New Issue
Block a user