Find the Best Cosmetic Hospitals

Explore trusted cosmetic hospitals and make a confident choice for your transformation.

“Invest in yourself — your confidence is always worth it.”

Explore Cosmetic Hospitals

Start your journey today — compare options in one place.

How to Setup SVN Server with Apache2 in Ubuntu

This article will help you for step by step setup of Subversion (svn) server on Ubuntu 18.04 LTS & 16.04 LTS systems.

Step 1 – Install Apache

First of all, you need to install the Apache webserver to access the svn server using HTTP URLs. Skip this step if you already have Apache web server on your system.

sudo apt-get update
sudo apt-get install apache2

Step 2 – Install SVN Server

Use the following command to install subversion packages and their dependencies. Also, install svn module for Apache libapache2-mod-svn packages on your system.

sudo apt-get install subversion libapache2-mod-svn libapache2-svn libsvn-dev

After installation, enable required Apache modules and restart Apache service.

sudo a2enmod dav dav_svn
sudo service apache2 restart

Step 3 – Create First SVN Repository

Use the following commands to create your first svn repository with name myrepo. Also, set the required permissions on newly created directories.

sudo mkdir -p /var/lib/svn/
sudo svnadmin create /var/lib/svn/myrepo

sudo chown -R www-data:www-data /var/lib/svn
sudo chmod -R 775 /var/lib/svn

Step 4 – Create Users for Subversion

Now create first svn user in /etc/apache2/dav_svn.passwd file. These users will use for authentication of svn repositories for checkout, commit processes.

sudo touch /etc/apache2/dav_svn.passwd
sudo htpasswd -m /etc/apache2/dav_svn.passwd admin

To create additional users, use following commands.

sudo htpasswd -m /etc/apache2/dav_svn.passwd user1
sudo htpasswd -m /etc/apache2/dav_svn.passwd user2

Step 5 – Configure Apache with Subversion

Subversion Apache module package creates an configuration file /etc/apache2/mods-enabled/dav_svn.conf. You just need to make necessary changes to it.

sudo vi /etc/apache2/mods-enabled/dav_svn.conf
Alias /svn /var/lib/svn
<Location /svn>

   DAV svn
   SVNParentPath /var/lib/svn

   AuthType Basic
   AuthName "Subversion Repository"
   AuthUserFile /etc/apache2/dav_svn.passwd
   Require valid-user
     
</Location>

Save the file and restart the Apache service to apply the new configuration.

sudo service apache2 restart

Step 6 – Access Repository in Browser

Use HTTP URLs to access your repository in the browser. It will prompt for authentication. Use login credentials created in Step 5. Change example.com with your system hostname, domain name or IP address.

 http://example.com/svn/myrepo/
Install Svn Server 1

Find Trusted Cardiac Hospitals

Compare heart hospitals by city and services — all in one place.

Explore Hospitals
I'm Rajesh Kumar, a DevOps, SRE, DevSecOps, Cloud, and Platform Engineering expert passionate about sharing practical knowledge, real-world experiences, and industry best practices. I have worked at Cotocus and regularly write about technology, travel, investing, health, product reviews, and digital marketing through my various platforms. I publish technical articles at DevOps School, travel stories at Holiday Landmark, stock market insights at Stocks Mantra, health and fitness guidance at My Medic Plus, product reviews at TrueReviewNow, and SEO and digital marketing strategies at Wizbrand.

Related Posts

Maven POM Explained: Structure, Inheritance, and Practical pom.xml Examples

The Project Object Model (POM) is Maven’s central configuration file and the source of truth for how a Java project is built. This guide covers required fields, inheritance (Super POM and parent POM), and how Maven creates the effective build configuration.

Read More

Maven issueManagement: Configure Issue Tracker Metadata Correctly in pom.xml

Learn what Maven’s issueManagement section does, how to configure it in pom.xml, and how to validate that consumers can find your issue tracker metadata.

Read More

Build Automation in DevOps: Workflow Design, Tooling Choices, and CI Pipeline Examples

The original post only embedded a slide deck, so this revised guide provides a complete, practical reference for build automation in DevOps. Learn the workflow, compare common tools, and start from reusable Makefile and CI pipeline examples.

Read More

Build Automation in DevOps: Practical Workflows, CI Examples, and Tool Choices

This updated guide explains how to move from manual builds to reliable, repeatable automation in a DevOps workflow. It includes a reference pipeline, real command examples, and a side-by-side tool comparison.

Read More

Configuration Management in DevOps: Concepts, Tooling, and a Practical Workflow

This guide explains how configuration management works in modern DevOps teams, compares common tools, and shows a practical Ansible example. It also preserves the original SlideShare reference from the legacy post.

Read More

Configuration Management in DevOps: Workflow, Tool Comparison, and an Ansible Example

This guide explains configuration management for DevOps teams: what it solves, how it fits into delivery workflows, and how major tool options compare. It also includes a practical Ansible example you can adapt for real environments.

Read More
Subscribe
Notify of
guest
2 Comments
Newest
Oldest Most Voted
niraav
niraav
3 years ago

what i do next how i use it

Gayan R.
Gayan R.
3 years ago

Good tutorial. Thanks !!

2
0
Would love your thoughts, please comment.x
()
x