File README changed (mode: 100644) (index 619aed8..436de0b) |
16 |
16 |
|
|
17 |
17 |
== Install == |
== Install == |
18 |
18 |
. Edit /etc/rocketgit/config.php |
. Edit /etc/rocketgit/config.php |
|
19 |
|
. Edit /etc/httpd/conf.d/rocketgit.conf |
|
20 |
|
|
|
21 |
|
. Install and configure Apache |
|
22 |
|
# yum install httpd |
|
23 |
|
# systemctl enable httpd.service |
|
24 |
|
# systemctl start httpd.service |
19 |
25 |
|
|
20 |
26 |
. Install and configure PostgreSQL server |
. Install and configure PostgreSQL server |
21 |
27 |
# yum install postgresql-server |
# yum install postgresql-server |
|
49 |
55 |
# setsebool -P httpd_can_network_connect_db on |
# setsebool -P httpd_can_network_connect_db on |
50 |
56 |
# setsebool -P httpd_can_network_memcache on |
# setsebool -P httpd_can_network_memcache on |
51 |
57 |
# setsebool -P httpd_can_sendmail on |
# setsebool -P httpd_can_sendmail on |
|
58 |
|
|
|
59 |
|
. Edit firewall to permit port git, http and https |
File inc/repo/repo_page.php changed (mode: 100644) (index 910d698..74b2678) |
... |
... |
$_menu .= "<br />\n"; |
22 |
22 |
|
|
23 |
23 |
$_body = ""; |
$_body = ""; |
24 |
24 |
|
|
25 |
|
$ri = rg_repo_info($db, $repo_id, $repo); |
|
26 |
|
if (($ri['ok'] != 1) || ($ri['deleted'] == 1)) { |
|
|
25 |
|
$repo_ok = rg_repo_ok($repo); |
|
26 |
|
if ($repo_ok === TRUE) { |
|
27 |
|
$ri = rg_repo_info($db, $repo_id, $repo); |
|
28 |
|
if (($ri['ok'] != 1) || ($ri['exists'] != 1) || ($ri['deleted'] == 1)) |
|
29 |
|
$repo_ok = FALSE; |
|
30 |
|
} |
|
31 |
|
|
|
32 |
|
if ($repo_ok !== TRUE) { |
27 |
33 |
$_body .= "Invalid repository!"; |
$_body .= "Invalid repository!"; |
28 |
34 |
// force subop 0 |
// force subop 0 |
29 |
35 |
$subop = 0; |
$subop = 0; |
File inc/util.inc.php changed (mode: 100644) (index f47325c..6b875ed) |
... |
... |
function rg_re_repopage($repo_id, $repo_name) |
87 |
87 |
if (isset($_REQUEST['rewrite_engine'])) |
if (isset($_REQUEST['rewrite_engine'])) |
88 |
88 |
return "/" . $repo_name; |
return "/" . $repo_name; |
89 |
89 |
|
|
90 |
|
return $_SERVER['PHP_SELF'] . "?op=repo&subop=2&repo_name=" . $repo_name; |
|
|
90 |
|
return $_SERVER['PHP_SELF'] . "?op=repo_page&repo_name=" . $repo_name; |
91 |
91 |
} |
} |
92 |
92 |
|
|
93 |
93 |
function rg_var_str($name) |
function rg_var_str($name) |
File samples/config.php changed (mode: 100644) (index 38105f3..dca94e1) |
... |
... |
$rg_session_time = 3600; |
16 |
16 |
$rg_keys_file = $rg_base . "/.ssh/authorized_keys"; |
$rg_keys_file = $rg_base . "/.ssh/authorized_keys"; |
17 |
17 |
|
|
18 |
18 |
// Scripts |
// Scripts |
19 |
|
$rg_scripts = "/usr/share/rocketgit/scripts"; |
|
|
19 |
|
$rg_scripts = "/usr/share/rocketgit"; |
20 |
20 |
|
|
21 |
21 |
// Allowed repo names (regular expression) |
// Allowed repo names (regular expression) |
22 |
22 |
$rg_repo_allow = '/^[A-Za-z0-9_.-]*$/'; |
$rg_repo_allow = '/^[A-Za-z0-9_.-]*$/'; |