Server Manager 2 Howto incorporate a legacy contrib
Introduction
There are 3 possibilities for incorporating an existing (legacy) contrib into Server manager 2:
- Re-code the contrib into the Mojolicious environment in which SM2 is written. This is documented here.
- Code up a "dummy" perl panel using mojolicious (see example below) which is inserted uatomatically into the menu and calls the "embedded.html.ep" template file.
- Just import the current contrib and access it through the "Legacy" category on the menu.
This page explains (2) and (3) in a bit more detail.
Code up a dummy page which calls the legacy panel
If you want to be able to control the position and category in the menu for the legacy contrib then you'll need to create a perl program in: the directory:
/usr/share/smanager/SrvMngr/Controller
Here is an example for the smeserver-userpanel contrib:
package SrvMngr::Controller::Userpanelaccess;
#----------------------------------------------------------------------
# heading : User management
# description : User Panel Access
# navigation : 2000 150
# menu :
#----------------------------------------------------------------------
# name : userpanelaccess, method : get, url : /userpanelaccess, ctlact : Userpanelaccess#main
#
# routes : end
#----------------------------------------------------------------------
use strict;
use warnings;
use Mojo::Base 'Mojolicious::Controller';
use Locale::gettext;
use SrvMngr::I18N;
use SrvMngr qw(theme_list init_session);
#use SrvMngr::Model::Main;
sub main {
my $c = shift;
$c->app->log->info($c->log_req);
my $title = $c->l('User panel access');
$c->stash( title => $title, modul => 'https://mailserver.bjsystems.co.uk/server-manager/cgi-bin/userpanelaccess', height => 600 );
$c->render(template => 'embedded');
}
1;
This file will need to be here:
/usr/share/smanager/SrvMngr/Controller/Userpanelaccess.pm
Note the menu entries at the top, and the route specification (the capitalisation and case matching is important here)
Also note the full URL for the SM1 (legacy) contrib, and also the window length (it defaults to 600px if you do not specify).
This all that is necessary to customise the menu entry for a legacy contrib.
Just install the contribs rpm and call it from the "Legacy" category
Server manager 2 will scan for installed contribs, and any that are not fully compatible with Mojolicious will just load the menu entry, using the package name as a link, under the "Legacy" category, normally at the bottom of the menu stack.
The need to login into Server Manager 1
If the legacy contrib does not show after clicking on the menu entry (either for mode (2) or (3) above), then it is probably that you are not logged into SM1. This can be achieved using the button in the top border of SM2 titled "Legacy SM". You can almost certainly use the same credentials that you used to go into SM2. Unfortunately the two programs use different login mechanisms.
Bugs
Please raise bugs under the SME-Server section in bugzilla
and select the component or use this link
Below is an overview of the current issues for this package:
ID | Product | Version | Status | Summary (73 tasks) ⇒ |
---|---|---|---|---|
12652 | SME Server 11.X | unspecified | CONFIRMED | Unable to add an ibay |
12645 | SME Server 11.X | unspecified | CONFIRMED | smanager - Wokstation Backup - attempt verify backup fails, does not list backups |
12644 | SME Server 11.X | unspecified | CONFIRMED | smanager - selecting workstation backup using a removeable device no devices displayed in form |
12643 | SME Server 11.X | unspecified | CONFIRMED | Error message in logs on Startup 'Argument "" isn't numeric' |
12641 | SME Server 11.X | unspecified | CONFIRMED | Backup or Restore - when selected no drop down displayed to select method |
12640 | SME Server 11.X | unspecified | CONFIRMED | Admin User forward not displayed in user table |
12608 | SME Server 11.X | unspecified | CONFIRMED | AH01215: CGI::param called in list context can lead to vulnerabilities |
12498 | SME Server 10.X | 10.1 | RESOLVED | Regression - menu restore does not work |
12491 | SME Server 11.X | unspecified | CONFIRMED | Mail Log analysis - qmail-q based options need to run as root or qmail |
12488 | SME Server 10.X | 10.1 | RESOLVED | Legacy contribs (ones not converted to SM2 / mojo code) are left in the menu at the end and appear in a new browser window / tab |
12485 | SME Server 11.X | unspecified | CONFIRMED | Run the server manager perl files through the prettifier. |
12484 | SME Server 11.X | unspecified | CONFIRMED | Make sure that the categories/sections in the menu are in the same order. |
12483 | SME Server 10.X | 10.1 | RESOLVED | hos_ERROR_CREATING_HOST on adding new hostname |
12482 | SME Server 11.X | unspecified | CONFIRMED | Make login by ordinary user show correct menu |
12480 | SME Server 10.X | 10.1 | RESOLVED | NFR: Suppress the version number in the footer unless user logged in. |
12479 | SME Server 10.X | 10.1 | RESOLVED | Click on "add domain" and it goes to corporate DNS Settings. |
12478 | SME Server 10.X | 10.1 | RESOLVED | After creating I-bay it was not visible in the ibay list. |
12476 | SME Server 10.X | 10.1 | RESOLVED | Re-organise menu as per discussions on Rocket |
12472 | SME Server 10.X | 10.1 | UNCONFIRMED | SM2 XTGeoipRev=enabled != displays as == |
12471 | SME Server 10.X | 10.1 | UNCONFIRMED | SM2 email-filtering spam settings display or change incorrectly |
12467 | SME Server 10.X | 10.1 | RESOLVED | Icon not shown when second page selected on dataTable table |
12466 | SME Server 10.X | 10.1 | RESOLVED | Add export buttons to tables in SM2 default theme. |
12465 | SME Server 10.X | 10.1 | RESOLVED | Update smeserver-manager-jsquery to fix left alignment of tables |
12464 | SME Server 10.X | 10.1 | RESOLVED | Server Manager 2 needs to save and restore menu organisation |
12459 | SME Server 10.X | 10.0 | RESOLVED | Create rpm - smeserver-manager-jquery |
12458 | SME Server 10.X | 10.1 | RESOLVED | Update SM2 to use jquery plugin dataTable for tables |
12457 | SME Server 10.X | 10.1 | RESOLVED | Experiment with making tables sortable and filterable and paged - using jquery. |
12446 | SME Server 11.X | unspecified | CONFIRMED | Initial screen - immediately after install - fails to show translated message |
12444 | SME Server 11.X | unspecified | CONFIRMED | Proxy Error following software update |
12442 | SME Server 10.X | 10.1 | RESOLVED | Default theme for SM2 submit button does not reflect hover or click |
12428 | SME Server 10.X | 10.1 | RESOLVED | SM2 Login button does not highlight when you press it. - default Theme |
12392 | SME Server 10.X | 10.1 | VERIFIED | Domains panel does not show borders around table of domains |
12387 | SME Server 11.X | unspecified | CONFIRMED | Server Manager 2 should open unconverted contribs/panels in the current page, possibly within an iframe |
12294 | SME Server 10.X | 10.1 | VERIFIED | Correct Requires in systemd service file |
12245 | SME Server 11.X | unspecified | CONFIRMED | Menu formatting with Server Manager 2 and AdminLTE |
12209 | SME Server 10.X | 10.0 | VERIFIED | Only show Reconfigure button and message after an update if UnsavedChanges='yes' |
12112 | SME Server 10.X | 10.0 | VERIFIED | update to httpd 2.4 syntax (SM2) |
11989 | SME Server 10.X | 10.0 | RESOLVED | Rollup changes including AdminLTE 3.1 |
11906 | SME Server 10.X | 10.0 | RESOLVED | Sort out spacing in menu when small fonts selected |
11881 | SME Server 10.X | 10.0 | RESOLVED | Browser Error in js for AdminLTE version extraction |
11880 | SME Server 10.X | 10.0 | RESOLVED | Browser error on non login pages (smeserver-manager-AdminLTE) |
11863 | SME Server 10.X | 10.0 | RESOLVED | Update css and checkbox for dark mode |
11861 | SME Server 10.X | 10.0 | VERIFIED | Update to AdminLTE 3.2 |
11846 | SME Server 10.X | 10.0 | RESOLVED | Warning from Browser when jquery loaded - unable to find .map file |
11833 | SME Server 10.X | 10.0 | RESOLVED | More formatting |
11830 | SME Server 10.X | 10.0 | RESOLVED | Update Datetime and reboot ep files to help AdminLTE |
11827 | SME Server 10.X | 10.0 | VERIFIED | Fix format of datetime panel |
11826 | SME Server 10.X | 10.0 | RESOLVED | More format changes to make it compatible |
11825 | SME Server 10.X | 10.0 | RESOLVED | Review configuration panel - In Server-Gateway, External IP and DHCP range not properly displayed |
11824 | SME Server 10.X | 10.0 | RESOLVED | User and Hostnames list does not act responsivly as window is made smaller |
11823 | SME Server 10.X | 10.0 | RESOLVED | In Review Configuration - IP address not show correctly for Server Gateway |
11822 | SME Server 10.X | 10.0 | RESOLVED | In Review Configuration virtual domains not aligned. |
11821 | SME Server 10.X | 10.0 | RESOLVED | Mail log file analysis shows blank |
11817 | SME Server 11.X | unspecified | CONFIRMED | Get Breadcrumb trail working |
11816 | SME Server 10.X | 10.0 | VERIFIED | Add Forgotten Password link to login panel |
11815 | SME Server 10.X | 10.0 | RESOLVED | Bring Group add and update panels into line with others |
11810 | SME Server 11.X | unspecified | CONFIRMED | License panel is left truncated, does not flow. |
11809 | SME Server 11.X | unspecified | CONFIRMED | Lack of a space after full stop and comma in English version of Server Manager2 panel descriptions in some places. |
11793 | SME Server 10.X | 10.1 | RESOLVED | For smeserver-manager - add module class to div id="module" |
11785 | SME Server 10.X | 10.0 | RESOLVED | Sort out alignment of descriptions and inputs on panels, and make work for mobile screens |
11783 | SME Server 10.X | 10.0 | RESOLVED | Bring update event into line with smanager update event |
11782 | SME Server 10.X | 10.0 | RESOLVED | Fix up Configuration Review panel |
11781 | SME Server 10.X | 10.0 | RESOLVED | Update login screen and add password visibility |
11780 | SME Server 10.X | 10.0 | RESOLVED | Add in dummy classes to div in each ep file for future themes |
11708 | SME Server 10.X | 10.0 | RESOLVED | CSRF security check should fully protect smeserver-manager |
11623 | SME Server 10.X | 10.0rc1 | RESOLVED | Update default.ep.html to new contribs-header and remove heading from status line |
11572 | SME Server 10.X | 10.0rc1 | RESOLVED | Update to AdminLTE 3.1 |
11571 | SME Server 10.X | 10.0rc1 | RESOLVED | Theme switch no longer works. |
11478 | SME Server 11.X | unspecified | CONFIRMED | Configuration report (under Server Manager/Report a bug) Includes some parts of the standard install |
11185 | SME Server 10.X | 10.0a5 | RESOLVED | New version for smeserver-manager |
10926 | SME Server 10.X | 10.0a4 | VERIFIED | CSRF time-out during yum update in server-manager |
7463 | SME Server 11.X | unspecified | CONFIRMED | HeadingWeight Wrong in Server Panel navigation scripts |
5382 | SME Server 11.X | unspecified | CONFIRMED | Hostnames/addresses panel doesn't reject same IP with different mac |
Changelog
Only released version in smeserver are listed here.