Created
February 28, 2014 08:47
-
-
Save ict4eo/9267579 to your computer and use it in GitHub Desktop.
Dockerfile for SVN
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu | |
MAINTAINER Derek Hohls <[email protected]> | |
# make sure the package repository is up to date | |
RUN apt-get update | |
# general | |
RUN apt-get install -y gcc patch wget curl nano | |
# Install Subversion 1.8 and Apache | |
RUN apt-get install -y subversion apache2 libapache2-svn | |
# Create a repo | |
RUN svnadmin create /home/svn | |
# Set permissions | |
RUN addgroup subversion | |
RUN usermod -a -G subversion www-data | |
RUN chown -R www-data:subversion /home/svn | |
RUN chmod -R g+rws /home/svn | |
# Configure Apache to serve up Subversion | |
RUN /usr/sbin/a2enmod auth_digest | |
RUN rm /etc/apache2/mods-available/dav_svn.conf | |
ADD testrepo-conf/dav_svn.conf /etc/apache2/mods-available/dav_svn.conf | |
# Create password files. Pre-created with "user"/"pass" username and password. | |
RUN mkdir -p /etc/subversion | |
ADD testrepo-conf/passwd.htpasswd /etc/subversion/passwd.htpasswd | |
ADD testrepo-conf/passwd.htdigest /etc/subversion/passwd.htdigest | |
ADD testrepo-conf/authz.conf /etc/subversion/authz.conf | |
ENV APACHE_RUN_USER www-data | |
ENV APACHE_RUN_GROUP www-data | |
ENV APACHE_PID_FILE /var/run/apache2.pid | |
ENV APACHE_RUN_DIR /var/run/apache2 | |
ENV APACHE_LOCK_DIR /var/lock/apache2 | |
ENV APACHE_LOG_DIR /var/log/apache2 | |
# startup | |
ADD startup.sh /startup.sh | |
# Default port to execute the entrypoint (Apache) | |
CMD ["--port 80"] | |
# Set default container command | |
# ENTRYPOINT startup.sh | |
# EXPOSE 80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment