"Linux" Debian Jessie version installs 1.9 svn

Source: Internet
Author: User
Tags gpg

Today, when using the official MySQL Docker image, the SVN version is found to be problematic. Needs to be updated to version 1.9. Here's how.

Subversion 1.9 on Debian JessieNovember 4, views:250articlesDebian, Subversion, WANdisco

If you would the latest version of Subversion and prefer using the package manager like me, the following step s below would enable you-install Subversion 1.9 from the WANdisco repositories. At the time of writing, the latest version in the WANdisco repo is 1.9.2.

1 #!/bin/bash
2 # download the GPG key of the repository and add it to apt:
3 wget http://opensource.wandisco.com/wandisco-debian.gpg -O /tmp/wandisco-debian.gpg
4 # add downloaded key to apt
5 apt-key add /tmp/wandisco-debian.gpg
6 # create apt sources file for wandisco repo
7 echo"deb http://opensource.wandisco.com/debian/ jessie svn19"> /etc/apt/sources.list.d/wandisco.sources.list
8 # update apt and upgrade packages
9 apt-get update ; apt-get installsubversion subversion-tools

It's important to note, the Subversion install on Debian Jessie does does include a systemd start script for Svnserve. This problem can easily is solved with the service start script provided below. Create an executable file at with the /etc/init.d/svnserve contents below. Note the line in the OPTIONS script below would need to being updated to reflect your specific environment.

View Source print?
1 #!/bin/sh -e
2 ### BEGIN INIT INFO
3 # Provides:          subversion
4 # Required-Start:    $network
5 # Required-Stop:     $network
6 # Default-Start:     2 3 4 5
7 # Default-Stop:      0 1 6
8 # Short-Description: Start daemon at boot time
9 # Description:       Enable service provided by daemon.
10 ### END INIT INFO
11
12 test-f /usr/bin/svnserve || exit0
13
14 OPTIONS="-d -T -r /srv/svn --log-file /var/log/svn.log"
15
16 case"$1"in
17  start)
18   echo-n "Starting subversion daemon:"
19   echo-n " svnserve"
20   start-stop-daemon --start --quiet --oknodo --chuid www-data:www-data --exec/usr/bin/svnserve -- $OPTIONS
21   echo"."
22   ;;
23
24  stop)
25   echo-n "Stopping subversion daemon:"
26   echo-n " svnserve"
27   start-stop-daemon --stop --quiet --oknodo --exec/usr/bin/svnserve
28   echo"."
29   ;;
30
31  reload)
32   ;;
33
34  force-reload)
35   $0 restart
36   ;;
37
38  restart)
39   $0 stop
40   $0 start
41   ;;
42
43  *)
44   echo"Usage: /etc/init.d/svnserve(start|stop|reload|restart)"
45   exit1
46   ;;
47
48 esac
49
50 exit0

Once your script is in place and set as executable, you can test it with the command below. Assuming your test succeeds, you can then instruct Systemd to start of the service at boot time.

1 # Test our new svnserve service
2 /etc/init.d/svnserve start
3 # Enable at boot in systemd
4 update-rc.d svnserve enable

Resources:

https://oitibs.com/subversion-1-9-on-debian-jessie/

"Linux" Debian Jessie version installs 1.9 svn

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.