[open-ils-commits] r17574 - in trunk/Open-ILS: examples/apache src src/support-scripts web (dbs)
svn at svn.open-ils.org
svn at svn.open-ils.org
Fri Sep 10 12:04:54 EDT 2010
Author: dbs
Date: 2010-09-10 12:04:51 -0400 (Fri, 10 Sep 2010)
New Revision: 17574
Removed:
trunk/Open-ILS/src/cgi-bin/
Modified:
trunk/Open-ILS/examples/apache/eg.conf
trunk/Open-ILS/src/support-scripts/eg_db_config.pl
trunk/Open-ILS/web/Makefile.am
Log:
Remove the previously deprecated CGI interfaces for configuring the Evergreen system
The CGI interfaces have not been maintained; the interfaces available through
the Admin -> Server Administration menu in the staff client are the recommended
method for setting up new libraries in the organizational hierarchy,
permissions, copy statuses, and circulation rules.
Note that an adjustment to eg_vhost.conf is recommended to point to the
offline.pl script, which is the only remaining CGI script in use; this
should avoid conflicting Apache definitions for the /cgi-bin/ alias.
Addresses https://bugs.launchpad.net/evergreen/+bug/634984
Modified: trunk/Open-ILS/examples/apache/eg.conf
===================================================================
--- trunk/Open-ILS/examples/apache/eg.conf 2010-09-10 15:57:21 UTC (rev 17573)
+++ trunk/Open-ILS/examples/apache/eg.conf 2010-09-10 16:04:51 UTC (rev 17574)
@@ -53,8 +53,8 @@
# ----------------------------------------------------------------------------------
# System config CGI scripts go here
# ----------------------------------------------------------------------------------
-Alias /cgi-bin/ "/openils/var/cgi-bin/"
-<Directory "/openils/var/cgi-bin">
+Alias /cgi-bin/offline/ "/openils/var/cgi-bin/offline/"
+<Directory "/openils/var/cgi-bin/offline">
AddHandler cgi-script .cgi .pl
AllowOverride None
Options None
Modified: trunk/Open-ILS/src/support-scripts/eg_db_config.pl
===================================================================
--- trunk/Open-ILS/src/support-scripts/eg_db_config.pl 2010-09-10 15:57:21 UTC (rev 17573)
+++ trunk/Open-ILS/src/support-scripts/eg_db_config.pl 2010-09-10 16:04:51 UTC (rev 17574)
@@ -27,7 +27,6 @@
my ($dbhost, $dbport, $dbname, $dbuser, $dbpw, $help);
my $config_file = '';
my $build_db_sh = '';
-my $bootstrap_file = '';
my $offline_file = '';
my $prefix = '';
my $sysconfdir = '';
@@ -77,24 +76,6 @@
die "ERROR: Failed to update the configuration file '$config_file'\n";
}
-# write out the DB bootstrapping config
-sub create_db_bootstrap {
- my ($setup, $settings) = @_;
-
- open(FH, '>', $setup) or die "Could not write database setup to $setup\n";
-
- print "Writing database bootstrapping configuration to $setup\n";
-
- printf FH "\$main::config{dsn} = 'dbi:Pg:host=%s;dbname=%s;port=%d';\n",
- $settings->{host}, $settings->{db}, $settings->{port};
-
- printf FH "\$main::config{usr} = '%s';\n", $settings->{user};
- printf FH "\$main::config{pw} = '%s';\n", $settings->{pw};
-
- print FH "\$main::config{index} = 'config.cgi';\n";
- close(FH);
-}
-
# write out the offline config
sub create_offline_config {
my ($setup, $settings) = @_;
@@ -149,17 +130,14 @@
chdir($script_dir);
}
-my $bootstrap;
my $offline;
my $cschema;
my $uconfig;
my %settings;
GetOptions("create-schema" => \$cschema,
- "create-bootstrap" => \$bootstrap,
"create-offline" => \$offline,
"update-config" => \$uconfig,
- "bootstrap-file=s" => \$bootstrap_file,
"config-file=s" => \$config_file,
"build-db-file=s" => \$build_db_sh,
"service=s" => \@services,
@@ -194,10 +172,6 @@
$build_db_sh = File::Spec->catfile($script_dir, '../sql/Pg/build-db.sh');
}
-if (!$bootstrap_file) {
- $bootstrap_file = File::Spec->catfile($sysconfdir, 'live-db-setup.pl');
-}
-
if (!$offline_file) {
$offline_file = File::Spec->catfile($sysconfdir, 'offline-config.pl');
}
@@ -211,10 +185,9 @@
get_settings(\%settings);
if ($cschema) { create_schema(\%settings); }
-if ($bootstrap) { create_db_bootstrap($bootstrap_file, \%settings); }
if ($offline) { create_offline_config($offline_file, \%settings); }
-if ((!$cschema && !$uconfig && !$bootstrap && !$offline) || $help) {
+if ((!$cschema && !$uconfig && !$offline) || $help) {
print <<HERE;
SYNOPSIS
@@ -230,10 +203,6 @@
--config-file
specifies the opensrf.xml file. Defaults to /openils/conf/opensrf.xml
- --bootstrap-file
- specifies the database bootstrap file required by the CGI setup
- interface. Defaults to /openils/conf/live-db-setup.pl
-
--build-db-file
specifies the script that creates the database schema. Defaults to
Open-ILS/src/sql/pg/build-db.sh
@@ -247,9 +216,6 @@
Configures Evergreen database settings in the file specified by
--build-db-file.
- --create-bootstrap
- Creates the database bootstrap file required by the CGI setup interface
-
--create-offline
Creates the database setting file required by the offline data uploader
@@ -287,7 +253,7 @@
script with a complete set of commands:
perl Open-ILS/src/support-scripts/eg_db_config.pl --update-config \
- --service all --create-schema --create-bootstrap --create-offline \
+ --service all --create-schema --create-offline \
--user evergreen --password evergreen --hostname localhost --port 5432 \
--database evergreen
Modified: trunk/Open-ILS/web/Makefile.am
===================================================================
--- trunk/Open-ILS/web/Makefile.am 2010-09-10 15:57:21 UTC (rev 17573)
+++ trunk/Open-ILS/web/Makefile.am 2010-09-10 16:04:51 UTC (rev 17574)
@@ -11,7 +11,7 @@
reportsdir = $(DESTDIR)$(WEBDIR)/reports/
if BUILDILSWEB
-OILSWEB_INST = webcore-install offline-install cgi-bootstrap
+OILSWEB_INST = webcore-install offline-install
#webcore-install
@@ -32,7 +32,7 @@
$(OPENSRF_LIBS)/javascript/opensrf_xmpp.js
endif
-install-exec-local: webcore-install offline-install cgi-bootstrap
+install-exec-local: webcore-install offline-install
uninstall-hook:
rm -R $(opacextrasdir)
@@ -68,15 +68,6 @@
cp $(TMP)/offline.pl $(DESTDIR)$(CGIDIR)/offline/
chmod +x $(DESTDIR)$(CGIDIR)/offline/offline.pl
-cgi-bootstrap:
- @echo "Installing cgi's to $(DESTDIR)$(CGIDIR)"
- $(MKDIR_P) $(TMP)/cgi-bin
- $(MKDIR_P) $(DESTDIR)$(CGIDIR)
- for i in @top_srcdir@/Open-ILS/src/cgi-bin/*cgi; do xxx=`basename $$i`; perl -pe "s{##CONFIG##}{@sysconfdir@}" < $$i > $(TMP)/cgi-bin/$$xxx; done
- cp $(TMP)/cgi-bin/*cgi $(DESTDIR)$(CGIDIR)
- cp -r @top_srcdir@/Open-ILS/src/cgi-bin/support $(DESTDIR)$(CGIDIR)
- chmod 755 $(DESTDIR)$(CGIDIR)/*cgi
-
install-data-local:
$(MKDIR_P) $(DESTDIR)$(WEBDIR)/opac/common/js
for i in $(OPACJS); do \
More information about the open-ils-commits
mailing list