svn
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
svn [2009/08/12 06:44] – suapapa | svn [2013/08/03 05:04] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== backup/ | + | 저장소 생성 : http 프로토콜 사용으로 아래의 스크립트로 돌림 |
- | 덤프떠서 보내기 | + | |
<code bash> | <code bash> | ||
- | svnadmin | + | # |
+ | svnadmin | ||
+ | chown -R www-data.www-data $1 | ||
+ | </code> | ||
+ | ====== backup/restore ====== | ||
+ | 덤프 스크립트 | ||
+ | <code python> | ||
+ | #!/usr/ | ||
+ | import os, sys | ||
+ | |||
+ | def main(rootDir): | ||
+ | print os.path.realpath(rootDir) | ||
+ | repolist = os.listdir(rootDir) | ||
+ | repolist = map(lambda x: | ||
+ | print repolist | ||
+ | repolist = filter(os.path.isdir, | ||
+ | print repolist | ||
+ | |||
+ | dumplist = [] | ||
+ | for repo in repolist: | ||
+ | print ' | ||
+ | print ' | ||
+ | dumpName = ' | ||
+ | print ' | ||
+ | ret = os.system(' | ||
+ | if ret == 0: | ||
+ | dumplist.append(dumpName) | ||
+ | else: | ||
+ | sys.exit(1) | ||
+ | if not dumplist: | ||
+ | print ' | ||
+ | sys.exit(1) | ||
+ | print 'now making tar archive' | ||
+ | os.system(r' | ||
+ | +(' ' | ||
+ | |||
+ | if __name__ == ' | ||
+ | main(sys.argv[1]) | ||
</ | </ | ||
복구 | 복구 |
svn.1250059450.txt.gz · Last modified: 2013/08/03 05:04 (external edit)