自拍偷在线精品自拍偷,亚洲欧美中文日韩v在线观看不卡

Apache+Svn設置問題詳解

開發(fā) 項目管理
本文和大家學習一下Apache+SVN設置問題,主要包括建立SVNServer服務器和建立權限兩部分內(nèi)容,在這里和大家分享一下。

本節(jié)介紹一下SVN設置問題,開始是在win2003enterpriseserver下用Apache+Svn設置,希望通過本節(jié)的學習大家能夠掌握Apache+SVN設置的方法,歡迎大家一起來學習。下面是具體介紹。
1.建立SVNServe服務器
1)啟動服務器程序svnserve
A:-r直接指定到版本庫(稱之為單庫svnserve方式)
比如,有一個庫project1,位于D:\svn\project1
svnserve-d-rD:\svn\project1
此種方式建立的版本庫,訪問方式為:
Svn://127.0.0.1/
B:-r指定到版本庫的上級目錄(稱之多庫svnserve方式)
同樣,有一個庫project1,位于D:\svn\project1
如果使用以下命令啟動svnserve
svnserve-d-rD:\svn
此種方式建立的版本庫,訪問方式為:
Svn://127.0.0.1/project1/。我們再來看一下Apache+SVN設置過程中如何建立權限。

2.建立權限
1)svnserve.conf文件結構分析
每個建立的版本庫下,都存在/conf/svnserve.conf文件,此文件就是用于配置此版本庫的訪問權限。
在版本庫權限配置文件svnserve.conf中,以#開頭的行為注釋。建立版本庫后,默認文件內(nèi)容為:
 

  1. ###Thisfilecontrolstheconfigurationofthesvnservedaemon,ifyou  
  2. ###useittoallowaccesstothisrepository.(Ifyouonlyallow###accessthroughhttp:and/orfile:URLs,thenthisfileis###irrelevant.)  
  3. ###Visithttp://subversion.tigris.org/formoreinformation.  
  4. [general]  
  5. ###Theseoptionscontrolaccesstotherepositoryforunauthenticated  
  6. ###andauthenticatedusers.Validvaluesare"write","read",  
  7. ###and"none".Thesamplesettingsbelowarethedefaults.  
  8. #anon-access=read 
  9. #auth-access=write 
  10. ###Thepassword-dboptioncontrolsthelocationofthepassword  
  11. ###databasefile.Unlessyouspecifyapathstartingwitha/,  
  12. ###thefile'slocationisrelativetotheconfdirectory.  
  13. ###Uncommentthelinebelowtousethedefaultpasswordfile.  
  14. #password-db=passwd 
  15. ###Theauthz-dboptioncontrolsthelocationoftheauthorization  
  16. ###rulesforpath-basedaccesscontrol.Unlessyouspecifyapath  
  17. ###startingwitha/,thefile'slocationisrelativetotheconf  
  18. ###directory.Ifyoudon'tspecifyanauthz-db,nopath-basedaccess  
  19. ###controlisdone.  
  20. ###Uncommentthelinebelowtousethedefaultauthorizationfile.  
  21. #authzauthz-db=authz  
  22. ###Thisoptionspecifiestheauthenticationrealmoftherepository.  
  23. ###Iftworepositorieshavethesameauthenticationrealm,theyshould  
  24. ###havethesamepassworddatabase,andviceversa.Thedefaultrealm  
  25. ###isrepository'suuid.  
  26. #realm=MyFirstRepository 

此文件,大部分都以#開頭,為注釋部分。文件真實內(nèi)容只有一句:
[general]
Apache+SVN設置在以下講解時,只顯示出配置內(nèi)容,不顯示注釋。
首先來解釋以下兩句的意義:
anon-access=read
auth-access=write
anon-access表示沒有進行驗證的用戶的功能,有三個可選項:none,read,write。
none表示沒有什么權限,此時客戶端連接服務器時,客戶端就提示進行驗證用戶;
read表示有讀取本版本庫的內(nèi)容的權限,但不能進行commit操作;
write表示可以進行版本庫的讀寫的權限;
auth-access表示經(jīng)過了驗證的用戶的權限;
password-db=passwd
這個語句告訴svnserve.exe,用戶名與密碼放在passwd.文件中,對于passwd文件的結構后面再做說明authz-db=authz
告訴svnserve.exe,項目目錄訪問權限的相關配置是放在authz.文件中,此文件的設置是細分權限,具體結構下面將做說明;
所以,對于正常使用的版本管理,一般是要進行驗證的,典型的/conf/svnserve.conf一般為:
[general]
anon-access=none
auth-access=write
password-db=passwd
authz-db=authz
注意:每個配置行,都要頂頭寫,沒有空格。請期待下節(jié)有關Apache+SVN設置講解。

 【編輯推薦】

  1. SVN配置文檔新手指南
  2. 實用SVN配置教程淺析
  3. 詳解使用SVN配置自動更新WEB服務器
  4. Centos下SVN的安裝配置實用手冊
  5. SVN服務器安裝指導手冊
責任編輯:佚名
相關推薦

2010-05-19 15:45:23

Apache+SVN權

2010-05-27 16:18:58

SVN設置

2010-05-19 15:25:47

Apache+SVN權

2011-07-29 08:51:51

Apache

2010-05-19 15:15:24

Apache+SVN部

2010-05-19 15:00:18

Apache+SVN部

2010-05-27 09:41:05

SVN沖突

2010-05-27 15:53:35

SVN屬性設置

2010-06-02 15:51:01

SVN版本控制

2010-05-24 11:16:43

SVN更新URL

2010-05-24 09:11:06

SVN版本庫

2010-05-25 19:57:32

2010-06-01 15:11:08

SVN刪除文件

2010-05-25 17:35:12

SVN代理

2010-05-25 18:32:22

apache+svn+

2010-05-28 17:15:17

SVN分支與合并

2010-05-26 14:28:53

本地SVN

2010-05-31 13:23:43

SVN整合MyEcli

2010-05-20 12:43:37

SVN Update命

2010-06-01 12:36:04

SVN分支與合并
點贊
收藏

51CTO技術棧公眾號