• Home
  • Docker
  • Kubernetes
  • LLMs
  • Java
  • Ubuntu
  • Maven
  • Big Data
  • Archived
Install | Subversion (a version control server to manage your code revisions)
  1. References
  2. Installation (Ubuntu 18.04)
  3. Create the SVN repository
  4. Create the project structure: trunk/branches/tags
  5. Create a maven project
  6. Create a new branch
  7. Release the project
  8. Backup a local SVN repository
  9. Delete the project from SVN
  10. Access Subversion via the http protocol (http://)
  11. Configure SCM to use http
  12. Uninstall Subversion

  1. References
    See these pages for more details on how to install Subversion:
    https://help.ubuntu.com/lts/serverguide/subversion.html
    https://help.ubuntu.com/community/Subversion

    Prerequisites:
    • Install Apache Maven
    • Install Apache HTTP Server
    • Install Nexus Repository Manager
  2. Installation (Ubuntu 18.04)
    Run the following command to install Subversion:

    Verify the version of Subversion:
  3. Create the SVN repository
    Create a local directory that will hold the SVN repository:

    Run the following command "svnadmin create" to create the SVN repository:

    Verify that the SVN repository is created:

  4. Create the SVN project structure: trunk/branches/tags
    Create a local directory that will hold the SVN project structure:

    Run the following command "svn import" to create the SVN project structure:

    Verify that the SVN folders are created:

    Notes: You can also use the following path "file:///data/subversion/repositories/myproject/mtitek-svn-test"
  5. Create a maven project
    Create a local directory that will hold the maven project:

    Run the following command "mvn archetype:generate" to create the maven project:

    Commit the maven project to SVN:

    Verify that the project is commited:

    Checkout the project from SVN:
  6. Create a new branch
    Add the scm configuration to "pom.xml" file:


    Commit the modifications to SVN:

    Create a new branch:

    Verify that the new branch is created:

    Checkout the new branch:

    Verify the project version and the scm configuration in the "pom.xml":

  7. Release the project
    Before you start this section, please note that you might get this error if run the command mvn release:perform:

    This might happen if your Nexus or equivalent repository manager is not configured, or your maven project doesn't have a distribution management element. Please see this page for more details on how to configure Nexus: Nexus Repository Manager

    Run the following commands to release the project:

    • Go to "mtitek-svn-test-a" project:

    • Configure the "pom.xml" file of the project "mtitek-svn-test-a".
      Add a "distributionManagement" element to configure the nexus repositories Snapshots and Releases:

      Commit the modifications to SVN:

    • Run "mvn versions:use-releases" command:

    • Run "mvn release:prepare" command:


      Verify the project version in the "pom.xml" file:

      Verify the project version in the "pom.xml.releaseBackup" file:

    • Run "mvn release:perform" command:


      Verify that the released component was deployed to Nexus:
      Deployment - Nexus

    Verify that the new release is created:

    Checkout the new release:

    Verify the project version and the scm configuration in the 'pom.xml':

  8. Backup the SVN repository
    Run the following command (svnadmin dump) to backup the SVN repository:
  9. Delete the project from SVN
    Run the following command (svn delete) to delete a project from SVN:
  10. Access Subversion via the http protocol (http://)
    Please see this page for more details on how to install and configure Apache HTTP Server: Install Apache HTTP Server

    Configure Apache httpd to allow access to Subversion repositories:

    Add the following inside "VirtualHost" element:

    Configure a username/password to enforce authentication:

    Enable the 'dav_svn' apache module (if not already enabled):

    Create a new group 'subversion':

    Restart Apache:

    Verify that the http protocol is working:

    You can use the browser: http://localhost/svn/myproject/mtitek-svn-test/

    HTTP Access
  11. Configure SCM to use http
    Modify the 'pom.xml' file:


    Commit the modifications to SVN:

    Checkout the project:

    Verify the SVN information:
  12. Uninstall Subversion
    List Subversion installed packages:

    Uninstall Subversion:

    Uninstall Subversion and its dependencies:
© 2025  mtitek