Debian/Ubuntu下配置Subversion Server

本文介绍如何在Ubuntu系统中安装Apache2和SVN,并详细说明了配置Apache2以支持SVN服务的过程,包括创建项目目录、设置用户名密码及权限等步骤。
  • 安装Apache2
    #sudo apt-get install apache2
  • 安装SVN
    #sudo apt-get install subversion libapache2-svn
  • 配置Apache2的配置文件 /etc/apache2/mods-available/dav_svn.conf
    <Location /svn>
    DAV svn
    SVNParentPath /opt/svn/repos/
    AutoType Basic
    AutoName "My Respository"
    AutoUserFile /opt/svn/password
    Require valid-user
    </Location>
  • 创建项目目录
    #sudo svnadmin create /opt/svn/repos/myproject
  • 创建用户名和密码
    #sudo htpasswd -c /opt/svn/passwd robinhuang (第二次创建可取消-c)
  • 使Apache的某些模块有效
    #sudo a2enmod dav dav_fs dav_svn
  • 最后重载Apache
    #sudo /etc/init.d/apache2 force-reload
    注意:当创建一个项目之后,需要运行以下命令:
    #sudo chown -R www-data: /opt/svn/repos
    使得该项目的文件能够正常访问。
写一个dockerfile,要求如下: 1)从ubuntu:18.04拉取基础镜像 2)修改默认为bash 3)更新软件源为以下: # 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释 deb http://rdsource.tp-link.com/ubuntu/ bionic main restricted universe multiverse # deb-src http://rdsource.tp-link.com/ubuntu/ bionic main restricted universe multiverse deb http://rdsource.tp-link.com/ubuntu/ bionic-updates main restricted universe multiverse # deb-src http://rdsource.tp-link.com/ubuntu/ bionic-updates main restricted universe multiverse deb http://rdsource.tp-link.com/ubuntu/ bionic-backports main restricted universe multiverse # deb-src http://rdsource.tp-link.com/ubuntu/ bionic-backports main restricted universe multiverse deb http://rdsource.tp-link.com/ubuntu/ bionic-security main restricted universe multiverse # deb-src http://rdsource.tp-link.com/ubuntu/ bionic-security main restricted universe multiverse # 预发布软件源,不建议启用 # deb http://rdsource.tp-link.com/ubuntu/ bionic-proposed main restricted universe multiverse # deb-src http://rdsource.tp-link.com/ubuntu/ bionic-proposed main restricted universe multiverse 4)更新所有软件 5)安装以下软件 build-essential ccache ecj fastjar file g++ gawk \ gettext git java-propose-classpath libelf-dev libncurses5-dev \ libncursesw5-dev libssl-dev python python2.7-dev python3 unzip wget \ python3-distutils python3-setuptools python3-dev rsync subversion \ swig time xsltproc zlib1g-dev 6)清理下载缓存
最新发布
11-01
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值