Commit 0f4da68b authored by Leigh B Stoller's avatar Leigh B Stoller

Add IMS as a fast path (fcgid) entry point.

parent f431479c
......@@ -89,7 +89,7 @@ my $DB;
sub InitDBHandle()
{
$DB = GeniDB->New("ims");
$DB = GeniDB->New("ims") if (!defined($DB));
}
#
......
......@@ -49,7 +49,8 @@ all: Genixmlrpc.pm GeniResponse.pm \
protogeni-ses.pm geni-am.pm geni-ma.pm geni-sa.pm \
protogeni-wrapper.pl protogeni-console.pl protogeni-portal.pm \
protogeni-ims.pm cluster-wrapper.pl ClusterWrapper.pm ProtoGeniDefs.pm \
protogeni-cluster.pm ch-wrapper.pl cm-wrapper.pl sa-wrapper.pl
protogeni-cluster.pm ch-wrapper.pl cm-wrapper.pl sa-wrapper.pl \
ims-wrapper.pl
include $(TESTBED_SRCDIR)/GNUmakerules
......@@ -66,6 +67,7 @@ install-libs: $(INSTALL_LIBDIR)/Genixmlrpc.pm \
$(INSTALL_DIR)/protogeni/xmlrpc/ch-wrapper.pl \
$(INSTALL_DIR)/protogeni/xmlrpc/sa-wrapper.pl \
$(INSTALL_DIR)/protogeni/xmlrpc/cm-wrapper.pl \
$(INSTALL_DIR)/protogeni/xmlrpc/ims-wrapper.pl \
$(INSTALL_LIBDIR)/ClusterWrapper.pm \
$(INSTALL_LIBDIR)/ProtoGeniDefs.pm \
$(INSTALL_LIBDIR)/geni-am.pm \
......
......@@ -287,5 +287,24 @@ ProtoGeniDefs::AddModule("cluster",
}},
});
package ProtoGeniDefs::ProtogeniIMS;
use lib '@prefix@/lib';
use GeniIMS;
ProtoGeniDefs::AddModule("ims",
{
"PEMFILE" => "@prefix@/etc/genich.pem",
"DBNAME" => "geni-ch",
"DEFVERSION" => "1.01",
"METHODS" => {"1.01" => {
"GetVersion" => \&GeniIMS::GetVersion,
"GetCredential" => \&GeniIMS::GetCredential,
"PostImageInfo" => \&GeniIMS::PostImageInfo,
"GetImageInfo" => \&GeniIMS::GetImageInfo,
"DeleteImageInfo" => \&GeniIMS::DeleteImageInfo,
}},
});
1;
#!/usr/bin/perl -w
#
# Copyright (c) 2000-2017 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
# This file is part of the Emulab network testbed software.
#
# This file is free software: you can redistribute it and/or modify it
# under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or (at
# your option) any later version.
#
# This file is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
# License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this file. If not, see <http://www.gnu.org/licenses/>.
#
# }}}
#
use English;
#
# This gets invoked from apache mod_fcgid. Simply a wrapper ...
#
#
# Configure variables
#
my $PROG = "@prefix@/protogeni/xmlrpc/cluster-wrapper.pl";
$ENV{'MODULE'} = "ims";
#
# Run the real thing, and never return.
#
exec $PROG;
die("Could not exec $PROG: $!");
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment