moved perl modules from /usr/local/lib/site_perl to /usr/share/perl5


			
			
				3.0-u-redesign
			
			
		
Daniel Tiefnig 15 years ago
parent 65a57fea29
commit 4f757d26ac

10
debian/changelog vendored

@ -1,3 +1,13 @@
ngcp-www-admin (3.0.0) unstable; urgency=low
* moved framework from /usr/local to /usr/share
* created templates for centralized config
* renamed packages to comply with our global naming policy
* couple of smaller packaging and installer bugfixes
* packaging not compatible with last release, forced new major version
-- Daniel Tiefnig <dtiefnig@sipwise.com> Thu, 28 Oct 2010 15:17:20 +0200
ngcp-www-admin (2.1.0) unstable; urgency=medium ngcp-www-admin (2.1.0) unstable; urgency=medium
* per domain caller rewrite rules * per domain caller rewrite rules

1
debian/conffiles vendored

@ -1 +0,0 @@
/usr/local/etc/admin.conf

28
debian/control vendored

@ -1,16 +1,32 @@
Source: ngcp-www-admin Source: ngcp-www-admin
Section: admin Section: admin
Priority: extra Priority: extra
Maintainer: Michael Prokop <mprokop@sipwise.com> Maintainer: Daniel Tiefnig <dtiefnig@sipwise.com>
Build-Depends: debhelper (>= 5) Build-Depends: debhelper (>= 5), libtemplate-perl
Standards-Version: 3.8.3 Standards-Version: 3.9.1
Homepage: http://sipwise.com/ Homepage: http://sipwise.com/
Vcs-svn: https://dev.sipwise.com/svn/www_admin
Vcs-Browser: https://dev.sipwise.com/svn/www_admin Package: ngcp-templates-ce-www-admin
Architecture: all
Depends: ${shlibs:Depends}, ${misc:Depends}, ngcp-templates-ce-config
Conflicts: ngcp-templates-pro-www-admin
Provides: ngcp-templates-www-admin
Description: Configuration templates for the web-based admin interface
The package contains configuration file templates for the administrative
webinterface.
Package: ngcp-templates-pro-www-admin
Architecture: all
Depends: ${shlibs:Depends}, ${misc:Depends}, ngcp-templates-ce-config
Conflicts: ngcp-templates-ce-www-admin
Provides: ngcp-templates-www-admin
Description: Configuration templates for the web-based admin interface
The package contains configuration file templates for the administrative
webinterface.
Package: ngcp-www-admin Package: ngcp-www-admin
Architecture: all Architecture: all
Depends: ${shlibs:Depends}, ${misc:Depends}, ngcp-ossbss-billing (>= 2.1.1), ngcp-ossbss-voip (>= 2.1.1), libcatalyst-perl, libcatalyst-modules-perl, libcatalyst-engine-apache-perl Depends: ${shlibs:Depends}, ${misc:Depends}, ngcp-ossbss-billing (>= 2.1.1), ngcp-ossbss-voip (>= 2.1.1), libcatalyst-perl, libcatalyst-modules-perl, libcatalyst-engine-apache-perl, ngcp-templates-www-admin
Description: administration framework to configure the Sipwise NGCP Description: administration framework to configure the Sipwise NGCP
This package provides an administration framework which is used to This package provides an administration framework which is used to
configure the Sipwise NGCP. configure the Sipwise NGCP.

@ -0,0 +1 @@
ce/etc etc/ngcp-config/templates/

@ -0,0 +1 @@
pro/etc etc/ngcp-config/templates/

@ -0,0 +1,6 @@
lib usr/share/ngcp-www-admin/
root usr/share/ngcp-www-admin/lib/admin/
admin.yml usr/share/ngcp-www-admin/lib/admin/
script/admin_cgi.pl usr/share/ngcp-www-admin/script/
script/admin_fastcgi.pl usr/share/ngcp-www-admin/script/
script/admin_server.pl usr/share/ngcp-www-admin/script/

111
debian/rules vendored

@ -7,69 +7,96 @@
# This special exception was added by Craig Small in version 0.37 of dh-make. # This special exception was added by Craig Small in version 0.37 of dh-make.
# Uncomment this to turn on verbose mode. # Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1 # export DH_VERBOSE=1
b=$(CURDIR)/debian/build
build: build-stamp build: build-stamp
build-stamp: build-stamp:
dh_testdir dh_testdir
mkdir -p pro/etc/ngcp-www-admin pro/etc/apache2/sites-available
# Add here commands to compile the package. mkdir -p ce/etc/ngcp-www-admin ce/etc/apache2/sites-available
# $(MAKE) tpage --define PRO=true etc/admin.conf > pro/etc/ngcp-www-admin/admin.conf.tt2
tpage etc/admin.conf > ce/etc/ngcp-www-admin/admin.conf.tt2
tpage --define PRO=true etc/apache.site > pro/etc/apache2/sites-available/ngcp-www-admin.tt2
tpage etc/apache.site > ce/etc/apache2/sites-available/ngcp-www-admin.tt2
touch $@ touch $@
clean: clean:
dh_testdir dh_testdir
dh_testroot dh_testroot
rm -f build-stamp rm -f build-stamp
rm -rf $(b) pro ce
# Add here commands to clean up after the build process.
# $(MAKE) clean
dh_clean dh_clean
install: build install: build
dh_testdir dh_testdir
dh_testroot dh_testroot
dh_clean -k dh_clean -k
dh_installdirs usr/local/admin usr/local/admin/script/ dh_installdirs
# Add here commands to install the package into debian/ngcp-www-admin. ngcp-www-admin:
cp -a lib debian/ngcp-www-admin/usr/local/admin/ @echo "--- Building: $@"
cp -a root debian/ngcp-www-admin/usr/local/admin/lib/admin/ dh_installdirs -p$@ -P$(b)/$@
install -m 644 admin.yml debian/ngcp-www-admin/usr/local/admin/lib/admin/ dh_installdocs -p$@ -P$(b)/$@
install -m 644 -D etc/admin.conf debian/ngcp-www-admin/usr/local/etc/admin.conf dh_installchangelogs -p$@ -P$(b)/$@
install -m 644 -D etc/apache.site debian/ngcp-www-admin/usr/share/doc/ngcp-www-admin/apache.site dh_install -p$@ -P$(b)/$@
# we don't need admin_create.pl and admin_test.pl: dh_installexamples -p$@ -P$(b)/$@
install -m 755 script/admin_cgi.pl debian/ngcp-www-admin/usr/local/admin/script/ dh_installman -p$@ -P$(b)/$@
install -m 755 script/admin_fastcgi.pl debian/ngcp-www-admin/usr/local/admin/script/ dh_link -p$@ -P$(b)/$@
install -m 755 script/admin_server.pl debian/ngcp-www-admin/usr/local/admin/script/ dh_strip -p$@ -P$(b)/$@
# make sure we don't have any svn files inside the .deb: dh_compress -p$@ -P$(b)/$@
find debian/ngcp-www-admin -name \.svn -print0 | xargs -0 rm -rf dh_fixperms -p$@ -P$(b)/$@
#dh_perl -p$@ -P$(b)/$@
dh_makeshlibs -p$@ -P$(b)/$@ -V
dh_installdeb -p$@ -P$(b)/$@
dh_shlibdeps -p$@ -P$(b)/$@
dh_installdebconf -p$@ -P$(b)/$@
dh_gencontrol -p$@ -P$(b)/$@
dh_md5sums -p$@ -P$(b)/$@
dh_builddeb -p$@ -P$(b)/$@
ngcp-templates-ce-www-admin:
@echo "--- Building: $@"
dh_installdirs -p$@ -P$(b)/$@
dh_link -p$@ -P$(b)/$@
dh_installdocs -p$@ -P$(b)/$@
dh_installchangelogs -p$@ -P$(b)/$@
dh_install -p$@ -P$(b)/$@
dh_strip -p$@ -P$(b)/$@
dh_compress -p$@ -P$(b)/$@
dh_fixperms -p$@ -P$(b)/$@
dh_makeshlibs -p$@ -P$(b)/$@ -V
dh_installdeb -p$@ -P$(b)/$@
dh_shlibdeps -p$@ -P$(b)/$@
dh_installdebconf -p$@ -P$(b)/$@
dh_gencontrol -p$@ -P$(b)/$@
dh_md5sums -p$@ -P$(b)/$@
dh_builddeb -p$@ -P$(b)/$@
# Build architecture-dependent files here. ngcp-templates-pro-www-admin:
binary-arch: install @echo "--- Building: $@"
# We have nothing to do by default. dh_installdirs -p$@ -P$(b)/$@
dh_link -p$@ -P$(b)/$@
dh_installdocs -p$@ -P$(b)/$@
dh_installchangelogs -p$@ -P$(b)/$@
dh_install -p$@ -P$(b)/$@
dh_strip -p$@ -P$(b)/$@
dh_compress -p$@ -P$(b)/$@
dh_fixperms -p$@ -P$(b)/$@
dh_makeshlibs -p$@ -P$(b)/$@ -V
dh_installdeb -p$@ -P$(b)/$@
dh_shlibdeps -p$@ -P$(b)/$@
dh_installdebconf -p$@ -P$(b)/$@
dh_gencontrol -p$@ -P$(b)/$@
dh_md5sums -p$@ -P$(b)/$@
dh_builddeb -p$@ -P$(b)/$@
# Build architecture-independent files here. binary-all: build install
binary-indep: install
dh_testdir binary-indep: build install ngcp-www-admin \
dh_testroot ngcp-templates-ce-www-admin ngcp-templates-pro-www-admin
dh_installchangelogs
dh_installdocs
dh_installexamples
dh_installman
dh_link
dh_strip
dh_compress
dh_fixperms
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_md5sums
dh_builddeb
binary: binary-indep binary-arch binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install .PHONY: build clean binary-indep binary-arch binary install

@ -1,49 +1,33 @@
<config debugging="0" <config debugging="0"
billing_features="1" log4perlconf="/etc/ngcp-ossbss/logging.conf"
log4perlconf="/usr/local/etc/logging.conf" billing_features="[% www-admin.billing_features %]"
peering_features="1" peering_features="[% www-admin.peering_features %]"
voicemail_features="1" voicemail_features="[% www-admin.voicemail_features %]"
fax_features="1" fax_features="[% www-admin.fax_features %]"
li_features="0" cc_dial_prefix="[% www-admin.cc_dial_prefix %]"
cc_dial_prefix="00" ac_dial_prefix="[% www-admin.ac_dial_prefix %]"
ac_dial_prefix="0"
> >
<dashboard enabled="1" <dashboard enabled="[% www-admin.dashboard.enabled %]"
rrd_url_path="/rrd" rrd_url_path="/rrd"
/> />
<subscriber extension_features="1" <subscriber extension_features="[% www-admin.subscriber.extension_features %]"
audiofile_features="1" audiofile_features="[% www-admin.subscriber.audiofile_features %]"
/> />
<domain rewrite_features="1" <domain rewrite_features="[% www-admin.domain.rewrite_features %]"
audiofile_features="1" audiofile_features="[% www-admin.domain.audiofile_features %]"
vsc_features="1" vsc_features="[% www-admin.domain.vsc_features %]"
/> />
<default_admin_settings is_master="0" is_active="1" read_only="0" <default_admin_settings is_master="[% www-admin.default_admin_settings.is_master %]" is_active="[% www-admin.default_admin_settings.is_active %]"
show_passwords="1" call_data="0" lawful_intercept="0" /> read_only="[% www-admin.default_admin_settings.read_only %]" show_passwords="[% www-admin.default_admin_settings.show_passwords %]"
call_data="[% www-admin.default_admin_settings.call_data %]" lawful_intercept="[% www-admin.default_admin_settings.lawful_intercept %]" />
<fees_csv> <fees_csv>
<element_order>destination</element_order> [% FOREACH feecsvelement = www-admin.fees_csv.element_order %]
<element_order>zone</element_order> <element_order>[% feecsvelement %]</element_order>
<element_order>zone_detail</element_order> [% END %]
<element_order>onpeak_init_rate</element_order>
<element_order>onpeak_init_interval</element_order>
<element_order>onpeak_follow_rate</element_order>
<element_order>onpeak_follow_interval</element_order>
<element_order>offpeak_init_rate</element_order>
<element_order>offpeak_init_interval</element_order>
<element_order>offpeak_follow_rate</element_order>
<element_order>offpeak_follow_interval</element_order>
<element_order>use_free_time</element_order>
</fees_csv> </fees_csv>
<speed_dial_vsc_presets> <speed_dial_vsc_presets>
<vsc>*0</vsc> [% FOREACH speeddialvsc = www-admin.speed_dial_vsc_presets.vsc %]
<vsc>*1</vsc> <vsc>[% speeddialvsc %]</vsc>
<vsc>*2</vsc> [% END %]
<vsc>*3</vsc>
<vsc>*4</vsc>
<vsc>*5</vsc>
<vsc>*6</vsc>
<vsc>*7</vsc>
<vsc>*8</vsc>
<vsc>*9</vsc>
</speed_dial_vsc_presets> </speed_dial_vsc_presets>
</config> </config>

@ -1,15 +1,15 @@
# should be automatically set in ports.conf [% IF www-admin.apache.port != 443 %]
# Listen 443 Listen 443
# NameVirtualHost *:443 [% END %]
PerlSwitches -I/usr/local/admin/lib PerlSwitches -I/usr/share/ngcp-www-admin/lib
<VirtualHost *:443> <VirtualHost *:443>
ServerAdmin support@sipwise.com ServerAdmin [% www-admin.apache.serveradmin %]
ServerName YOUR.SERVER ServerName [% www-admin.apache.servername %]
SSLEngine on SSLEngine on
SSLCertificateFile /etc/apache2/ssl/YOUR.SERVER.crt SSLCertificateFile [% www-admin.apache.sslcertfile %]
SSLCertificateKeyFile /etc/apache2/ssl/YOUR.SERVER.pem SSLCertificateKeyFile [% www-admin.apache.sslcertkeyfile %]
PerlModule Apache2::RequestUtil admin PerlModule Apache2::RequestUtil admin
@ -20,33 +20,12 @@ PerlSwitches -I/usr/local/admin/lib
PerlResponseHandler admin PerlResponseHandler admin
</Location> </Location>
<Location /SOAP>
AuthName "ngcp NGCP Provisioning"
AuthType Basic
AuthUserFile /usr/local/etc/provisioning.htpasswd
Require valid-user
SetHandler perl-script
PerlHandler ngcp::Provisioning::SOAP
</Location>
<Location /XMLRPC>
AuthName "ngcp NGCP Provisioning"
AuthType Basic
AuthUserFile /usr/local/etc/provisioning.htpasswd
Require valid-user
SetHandler perl-script
PerlHandler Apache::XMLRPC::Lite
PerlSetVar dispatch_to '/usr/local/lib/site_perl/ngcp/Provisioning/backends'
</Location>
# requires module dumpio # requires module dumpio
# LogLevel debug # LogLevel debug
# DumpIOInput Off # DumpIOInput Off
# DumpIOOutput Off # DumpIOOutput Off
LogLevel info LogLevel [% www-admin.logging.apache.err.level %]
ErrorLog syslog ErrorLog syslog:[% www-admin.logging.apache.err.facility %]
CustomLog "|/usr/bin/logger -p daemon.info -t oss" combined CustomLog "|/usr/bin/logger -p [% www-admin.logging.apache.acc.facility %].[% www-admin.logging.apache.acc.level %] -t [% www-admin.logging.apache.acc.identity %]" combined
</VirtualHost> </VirtualHost>

Loading…
Cancel
Save