您好,登录后才能下订单哦!
密码登录
登录注册
点击 登录注册 即表示同意《亿速云用户服务条款》
这篇文章将为大家详细讲解有关Ubuntu16.04.5LTS怎么安装SVN,小编觉得挺实用的,因此分享给大家做个参考,希望大家阅读完这篇文章后可以有所收获。
更新源
sudo apt-get update
安装SVN
sudo apt-get install subversion
创建文件夹
sudo mkdir /home/svn sudo mkdir /home/svn/repository sudo chmod -R 777 /home/svn/repository sudo svnadmin create /home/svn/repository cd /home/svn/repository/ sudo chmod -R 777 db
修改svnserve.conf
cd /home/svn/repository/conf/ sudo vi svnserve.conf
修改这四行如下所示
anon-access = none 匿名用户不可读 auth-access = write 权限用户可写 password-db = passwd 密码文件为passwd authz-db = authz 权限文件为authz ### users have read and write access to the repository. anon-access = none auth-access = write ### The password-db option controls the location of the password ### database file. Unless you specify a path starting with a /, ### the file's location is relative to the directory containing ### this configuration file. ### If SASL is enabled (see below), this file will NOT be used. ### Uncomment the line below to use the default password file. password-db = passwd ### The authz-db option controls the location of the authorization ### rules for path-based access control. Unless you specify a path ### starting with a /, the file's location is relative to the ### directory containing this file. The specified path may be a ### repository relative URL (^/) or an absolute file:// URL to a text ### file in a Subversion repository. If you don't specify an authz-db, ### no path-based access control is done. ### Uncomment the line below to use the default authorization file. authz-db = authz ### The groups-db option controls the location of the groups file.
修改password文件,添加访问用户
sudo vi passwd [users] # harry = harryssecret # sally = sallyssecret lidata = lidata429
给用户增加目录权限
sudo vi authz [groups] # harry_and_sally = harry,sally # harry_sally_and_joe = harry,sally,&joe # [/foo/bar] # harry = rw # &joe = r # * = # [repository:/baz/fuz] # @harry_and_sally = rw # * = r [/] lidata=rw
启动服务,并且监听81端口
sudo svnserve -d -r /home/svn --listen-port 81
查看svn是否启动
ps -ef | grep svnserve
停止服务
kill all svnserve
关于“Ubuntu16.04.5LTS怎么安装SVN”这篇文章就分享到这里了,希望以上内容可以对大家有一定的帮助,使各位可以学到更多知识,如果觉得文章不错,请把它分享出去让更多的人看到。
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。