POST notification wrong time and no host address
Hello,
I have set up POST notification under contact information in Basic WebHost Manager to a php which then pushes the data to my telegram username. I test fire a notification from server contact->Contact manager and the test message received has the time mentioned in UTC as below while the server time is set in IST
[QUOTE]
This message confirms that "hostname" (IP) can send a message to you via Posturl.
This message was sent on Wednesday, January 17, 2018 at 4:13:59 PM UTC.
Also, the post data seem to not contain the "host" key or it is empty as I dont get any value for the "host" key. Is this all just because it is just a test notification?
Also, the post data seem to not contain the "host" key or it is empty as I dont get any value for the "host" key. Is this all just because it is just a test notification?
-
Hello, 1. As far as the hostname entry, could you verify that your server's hostname is properly listed in "WHM >> Change Hostname"? 2. You'd need to customize the notification template to utilize a different time zone if you want to use something other than UTC. We document how to customize the notification templates at: Notification Templates - Documentation - cPanel Documentation For example, to change the dates/times that appear in notifications, you'd first run the following commands to copy the origin_info.html.tmpl template file to the customization location: mkdir -p /var/cpanel/templates/icontact_templates/include cp -a /usr/local/cpanel/etc/icontact_templates/include/origin_info.html.tmpl /var/cpanel/templates/icontact_templates/include/
Then, edit the template file with a command line editor such as "vi":vi /var/cpanel/templates/icontact_templates/include/origin_info.html.tmpl
The entry you need to modify is:[% CPANEL.locale.maketext('The system generated this notice on [_1] at [_2] [asis,UTC].', CPANEL.iso_date(), CPANEL.iso_time()) %]
Thank you.0 -
Thank you for the link and guide Michael! The hostname is empty only for test notification while the real notification contains the hostname. I'll try to change the timezone. Regards, Vijai 0
Please sign in to leave a comment.
Comments
2 comments