{"id":210,"date":"2012-06-29T16:11:41","date_gmt":"2012-06-29T16:11:41","guid":{"rendered":"https:\/\/shan.info\/new\/virtualmin-domain-subversion-svn-hook-post-commit-public_html\/"},"modified":"2012-06-29T16:11:41","modified_gmt":"2012-06-29T16:11:41","slug":"virtualmin-domain-subversion-svn-hook-post-commit-public_html","status":"publish","type":"post","link":"https:\/\/shan.info\/new\/virtualmin-domain-subversion-svn-hook-post-commit-public_html\/","title":{"rendered":"virtualmin domain subversion svn hook post-commit public_html"},"content":{"rendered":"<p>1.<\/p>\n<p>services&#8211;<a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtualmin-svn\/index.cgi?show=gestion.estuday.com\" target=\"right\">Subversion Repositories<\/a>&#8211;creat a svn name as sitesvn<\/p>\n<p>2.<\/p>\n<p>\u6dfb\u52a0 \u670d\u52a1\u5668\u7aef \u53ea\u8bfb svn update \u7528\u6237<\/p>\n<p><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtual-server\/list_users.cgi?dom=133530082930713&amp;\" target=\"right\">Edit Users<\/a> &#8212; <a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtual-server\/edit_user.cgi?new=1&amp;web=1&amp;dom=133530082930713\">Add a website FTP access user<\/a> &#8212;<\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtual-server\/username2\">Username<\/a><\/b> &#8212; server@mydomain.com<\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtual-server\/password\">Password<\/a><\/b> &#8212; 123456<\/p>\n<p><a class=\"ui-hidden-table-title\"><b>Other user permissions<\/b><\/a><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtualmin-svn\/svn\">Subversion login enabled?<\/a><\/b> <input class=\"ui_radio\" name=\"virtualmin_svn\" value=\"1\" id=\"virtualmin_svn_1\" type=\"radio\" \/> <label for=\"virtualmin_svn_1\">Yes<\/label><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtualmin-svn\/roreps\">Read-only access to repositories<\/a><\/b><\/p>\n<p><b><b>Allowed repos<\/b><\/b><\/p>\n<p><b>sitesvn<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>\u6dfb\u52a0 \u8fdc\u7a0b\u53ef\u5199 \u7528\u6237<\/b><\/p>\n<p><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtual-server\/list_users.cgi?dom=133530082930713&amp;\" target=\"right\">Edit Users<\/a> &#8212; <a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtual-server\/edit_user.cgi?new=1&amp;web=1&amp;dom=133530082930713\">Add a website FTP access user<\/a> &#8212;<\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtual-server\/username2\">Username<\/a><\/b> &#8212; <a href=\"mailto:server@mydomain.com\">remote@mydomain.com<\/a><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtual-server\/password\">Password<\/a><\/b> &#8212; 123456<\/p>\n<p><a class=\"ui-hidden-table-title\"><b>Other user permissions<\/b><\/a><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtualmin-svn\/svn\">Subversion login enabled?<\/a><\/b> <input class=\"ui_radio\" name=\"virtualmin_svn\" value=\"1\" id=\"virtualmin_svn_1\" type=\"radio\" \/> <label for=\"virtualmin_svn_1\">Yes<\/label><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtualmin-svn\/reps\">Read\/write access to repositories<\/a><\/b><\/p>\n<p><b><b>Allowed repos<\/b><\/b><\/p>\n<p><b>sitesvn<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>3<\/b><\/p>\n<p><b>enable ssl for site<\/b><\/p>\n<p><b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/virtual-server\/edit_domain.cgi?dom=133530082930713\" target=\"right\">Edit Virtual Server<\/a> &#8212; <a class=\"ui-hidden-table-title\"><b>Enabled features<\/b><\/a> &#8212; <b><a href=\"https:\/\/88-190-210-17.rev.dedibox.fr:10000\/help.cgi\/virtual-server\/ssl\">SSL website enabled?<\/a><\/b><br \/><\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>4<\/b><\/p>\n<p><b>use ssh<\/b><\/p>\n<p><b>su as root<\/b><\/p>\n<p><b>\u6e05\u7a7a \u6587\u4ef6\u5939<br \/><\/b><\/p>\n<p><b>cd \/home\/<b><b>yourdomain<\/b><\/b>\/public_html<\/b><\/p>\n<p><b>rm -rf *<br \/><\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>cd \/home\/mydomain\/svn\/sitesvn\/hooks<br \/><\/b><\/p>\n<p><b>cp post-commit.tmpl post-commit<\/b><\/p>\n<p><b>vi <b>post-commit<\/b><\/b><\/p>\n<p><b><b><br \/><\/b><\/b><\/p>\n<p><b>#!\/bin\/sh<br \/>svn update \/home\/yourdomain\/public_html &#8211;username=server &#8211;password=123456 &#8211;non-interactive &gt;&gt; \/home\/yourdomain\/logs\/subversion_log<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>cd \/home\/<b>yourdomain<\/b>\/logs<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>touch subversion_log<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><span style=\"font-size: 18pt; color: #ff6600;\"><b>\u5207\u6362\u7528\u6237\u4e3a mydomain \u8fd0\u884c svn checkout<\/b><\/span><\/p>\n<p><span color=\"#ff6600\" size=\"5\" style=\"color: #ff6600; font-size: x-large;\"><b>su domainuser<\/b><\/span><\/p>\n<p><span color=\"#ff6600\" size=\"5\" style=\"color: #ff6600; font-size: x-large;\"><b><br \/><\/b><\/span><\/p>\n<p><b>svn co <a href=\"https:\/\/gestion.estuday.com\/svn\/sitesvn\/\">https:\/\/<b>yourdomain<\/b>\/svn\/sitesvn\/<\/a> \/home\/<b>yourdomain<\/b>\/public_html &#8211;username=server &#8211;password=123456<\/b><\/p>\n<p><b>p<\/b><\/p>\n<p><b>yes<\/b><\/p>\n<p><b>yes<\/b><\/p>\n<p><b><br \/><\/b><\/p>\n<p><b>\u4e0d\u662f\u5fc5\u987b \u5bb9\u6613\u51fa\u9519<\/b><\/p>\n<p>chown apache:yourdomain \/home\/yourdomain\/svn\/sitesvn\/hooks\/post-commit<br \/>chown apache:yourdomain \/home\/yourdomain\/logs\/subversion_log <br \/>chown -R apache:yourdomain \/home\/yourdomain\/public_html\/.svn<\/p>\n<p>&nbsp;<\/p>\n<p>chmod 770 \/home\/yourdomain\/svn\/sitesvn\/hooks\/post-commit<br \/>chmod 770 \/home\/yourdomain\/logs\/subversion_log <br \/>chmod 770 \/home\/yourdomain\/public_html\/.svn<\/p>\n<p><b><br \/><\/b><\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. services&#8211;Subversion Repositories&#8211;creat a svn name as sitesvn 2. \u6dfb\u52a0 \u670d\u52a1\u5668\u7aef \u53ea\u8bfb svn update \u7528\u6237 Edit Users &#8212; Add a website FTP access user &#8212; Username &#8212; server@mydomain.com Password &#8212; 123456 Other user permissions Subversion login enabled? Yes Read-only access to repositories Allowed repos sitesvn \u6dfb\u52a0 \u8fdc\u7a0b\u53ef\u5199 \u7528\u6237 Edit Users &#8212; Add a website FTP [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[51],"tags":[],"class_list":["post-210","post","type-post","status-publish","format-standard","hentry","category-webmin"],"_links":{"self":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/210","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/comments?post=210"}],"version-history":[{"count":0,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/210\/revisions"}],"wp:attachment":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/media?parent=210"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/categories?post=210"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/tags?post=210"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}