[Solved] SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Moderator: crythias

Locked
lajones
Znuny newbie
Posts: 2
Joined: 08 Apr 2020, 19:02
Znuny Version: 6.0.27
Real Name: Logan Jones
Company: OAG

[Solved] SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Post by lajones »

I've got

Code: Select all

$Self->{'SendmailModule::Port'} = '25';
in my Config.pm. When I go into the admin sysconfig interface, it shows the setting disabled. If I change the port to anything else in Config.pm, for instance

Code: Select all

$Self->{'SendmailModule::Port'} = '465';
or

Code: Select all

$Self->{'SendmailModule::Port'} = 'PotatoSalad';
the setting shows up in the admin sysconfig interface as enabled with the value specified. But when it's port 25 that's specified, I guess the interface is just seeing the default value and marking the setting disabled, despite the fact that it's explicitly defined in Config.pm.

Is there something else I have to add to tell it that I want the setting enabled even when I've specified port 25?
Last edited by lajones on 10 Apr 2020, 16:09, edited 1 time in total.
root
Administrator
Posts: 4251
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Post by root »

Hi Logan,

Settings made in Kernel/Config.pm are "final" and can't be changed in the SysConfig. Just comment them out or delete them to have full control over a setting in the SysConfig.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
lajones
Znuny newbie
Posts: 2
Joined: 08 Apr 2020, 19:02
Znuny Version: 6.0.27
Real Name: Logan Jones
Company: OAG

Re: SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Post by lajones »

root wrote: 10 Apr 2020, 06:57 Hi Logan,

Settings made in Kernel/Config.pm are "final" and can't be changed in the SysConfig. Just comment them out or delete them to have full control over a setting in the SysConfig.

- Roy
That doesn't really solve my problem, Roy. My problem is that I want to set it in Config.pm, but it only enables it if I've set it to something other than 25 in Config.pm. I want to set it to 25 in Config.pm and have it enabled. But if I set it to 25 in Config.pm, it's disabled. If I set it to anything other than 25 in Config.pm, it's enabled. But if I set it to 25 in Config.pm, it's disabled.

I want to set it to 25 in Config.pm and have it enabled.
jojo
Znuny guru
Posts: 15020
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Post by jojo »

it does not need to be enabled if it is on port 25. So the code works as designed
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
root
Administrator
Posts: 4251
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: SendmailModule::Port setting is disabled if it's specified as '25' in Config.pm

Post by root »

lajones wrote: 10 Apr 2020, 15:50 I want to set it to 25 in Config.pm and have it enabled.
Hi,
I would like to understand why. Maybe you can explain it.
Anyway, try this: remove it from Config.pm, Enable the setting in the SysConfig and deploy it. Then add the setting to Config.pm.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Locked