Hello, I need to install ssl vhost for nginx , after UAPI::SSL::install_ssl , but i don`t understand how to get information in script or right in module.
I`m add and register hook for UAPI::SSL::install_ssl
with module
I have all information , but haven`t root right use uapi
(example uapi --user=username DomainInfo single_domain_data domain=example.com) and write to nginx config.
Okey, i try use script with root right
I have root right , but i don`t know about who call this script and any information .
May be i dont understand how that work ? Any help .thx.
Sorry for bad English.
I`m add and register hook for UAPI::SSL::install_ssl
Code:
my $hooks = [
{
'category' => 'Cpanel',
'event' => 'UAPI::SSL::install_ssl',
'stage' => 'post',
'hook' => 'NginxSsl::install',
'exectype' => 'module',
}
Code:
sub install {
my ( $context, $data ) = @_;
#_more_logging( $context, $data );
my $user = $data->{user};
my $domain = $data->{args}->{domain};
#.....
}
(example uapi --user=username DomainInfo single_domain_data domain=example.com) and write to nginx config.
Okey, i try use script with root right
Code:
/usr/local/cpanel/bin/manage_hooks add script install.pl --manual --category Cpanel --event UAPI::SSL::install_ssl --stage post --exectype script --escalateprivs
May be i dont understand how that work ? Any help .thx.
Sorry for bad English.
Last edited by a moderator: