Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SUSEconfig for postfix and sendmail removed #59

Merged
merged 11 commits into from
Mar 1, 2013
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.24.14
2.24.15
8 changes: 8 additions & 0 deletions package/yast2-network.changes
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
-------------------------------------------------------------------
Wed Feb 27 22:42:42 UTC 2013 - mfilka@suse.com

- fate#313548, fate#309055 and fate#100011 in general. Removed
SUSEconfig calls for postfix and sendmail. Also related to
bnc#786665
- 2.24.15

-------------------------------------------------------------------
Tue Feb 12 14:00:05 CET 2013 - mvidner@suse.cz

Expand Down
4 changes: 2 additions & 2 deletions src/modules/DNS.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ global define boolean Write() {
/* Progress stage 1 */
_("Write hostname"),
/* Progress stage 2 */
_("Run SuSEconfig"),
_("Update configuration"),
/* Progress stage 3 */
_("Update /etc/resolv.conf")
];
Expand All @@ -318,7 +318,7 @@ global define boolean Write() {
sleep(sl);

/* Progress step 2/3 */
ProgressNextStage(_("Running SuSEconfig..."));
ProgressNextStage(_("Updating configuration..."));

/* Finish him */
RunSuSEconfig();
Expand Down
6 changes: 3 additions & 3 deletions src/modules/ISDN.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ global define boolean Write(boolean start) ``{
// stage 6/13
plist = add(plist, _("Write providers"));
// stage 7/13
plist = add(plist, _("Run SuSEconfig"));
plist = add(plist, _("Update configuration..."));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: without "..."

if (start) {
steps = 8;
// stage 8/13
Expand Down Expand Up @@ -475,8 +475,8 @@ global define boolean Write(boolean start) ``{

if(Abort()) return false;
// step 7 in writing current ISDN setup
ProgressNextStage(_("Running SuSEconfig..."));
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module isdn");
ProgressNextStage(_("Updating configuration..."));
SCR::Execute(.target.bash, "/etc/sysconfig/isdn/scripts/postprocess.isdn");
sleep(sl);

if(Abort()) return false;
Expand Down
4 changes: 2 additions & 2 deletions src/modules/Lan.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ global define boolean Write() {
/* Progress stage 9 */
if (!write_only) step_labels = add(step_labels, _("Activate network services"));
/* Progress stage 10 */
step_labels=add(step_labels, _("Run SuSEconfig"));
step_labels=add(step_labels, _("Update configuration"));
if (!NetworkService::IsManaged() && /*(boolean) SCR::Read(.init.scripts.exists, "smpppd") &&*/ !write_only )
{
/* Progress stage 11 */
Expand Down Expand Up @@ -575,7 +575,7 @@ y2internal("virt_net_proposal %1", virt_net_proposal);

if(Abort()) return false;
/* Progress step 10 */
ProgressNextStage(_("Running SuSEconfig..."));
ProgressNextStage(_("Updating configuration..."));
if(!write_only) RunSuSEconfig();
sleep(sl);

Expand Down
13 changes: 1 addition & 12 deletions src/modules/Remote.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,7 @@ global boolean Write() {
];

if (Mode::normal()) {
/* Progress stage 3+4 */
steps = add( steps, _("Run SuSEconfig") );
/* Progress stage 3 */
steps = add( steps, _("Restart the services") );
}

Expand Down Expand Up @@ -222,16 +221,6 @@ global boolean Write() {
sleep(sl);

if(Mode::normal ()) {
ProgressNextStage(_("Running SuSEconfig..."));
/* no longer needed - have been dropped from SuSEconfig
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module xdm");
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module kde3");
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module kdm3");*/

//Still needed for enabling/disabling remote administration
//because 'rcxdm reload' kills running X session if gdm is used
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module gdm");
sleep(sl);

boolean dm_was_running = Service::Status("xdm") == 0;

Expand Down
22 changes: 3 additions & 19 deletions src/routines/runtime.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -45,28 +45,12 @@ textdomain "network";
* @return true if success
*/
define boolean RunSuSEconfig() {
y2milestone("Running SuSEconfig ...");
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module apache 2>/dev/null");
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module sendmail 2>/dev/null");
SCR::Execute(.target.bash, "/sbin/SuSEconfig --module postfix 2>/dev/null");
y2milestone("Updating sendmail and/or postfix configuration.");
SCR::Execute(.target.bash, "/usr/lib/sendmail.d/update 2>/dev/null");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe link to documentation in comment?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be nice. But I don't know any documentation ;-)

SCR::Execute(.target.bash, "/usr/sbin/config.postfix 2>/dev/null");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As above. Just an idea.

return true;
}

/**
* Run one SuSEconfig module
* @param modul SuSEconfig module
* @return true if success
*/
define boolean RunSuSEconfigModule(string modul) {
if(modul == nil || modul == "") {
y2error("Wrong SuSEconfig module: %1", modul);
return false;
}
y2milestone("Running SuSEconfig module %1", modul);
return (SCR::Execute(.target.bash, sformat("/sbin/SuSEconfig --module %1", modul)) == 0);
}


/**
* Link detection
* @return true if link found
Expand Down
15 changes: 4 additions & 11 deletions testsuite/tests/runtime.out
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
Dump RunSuSEconfig
Execute .target.bash "/sbin/SuSEconfig --module apache 2>/dev/null" 0
Execute .target.bash "/sbin/SuSEconfig --module sendmail 2>/dev/null" 0
Execute .target.bash "/sbin/SuSEconfig --module postfix 2>/dev/null" 0
Execute .target.bash "/usr/lib/sendmail.d/update 2>/dev/null" 0
Execute .target.bash "/usr/sbin/config.postfix 2>/dev/null" 0
Return true
Execute .target.bash "/sbin/SuSEconfig --module apache 2>/dev/null" 1
Execute .target.bash "/sbin/SuSEconfig --module sendmail 2>/dev/null" 1
Execute .target.bash "/sbin/SuSEconfig --module postfix 2>/dev/null" 1
Execute .target.bash "/usr/lib/sendmail.d/update 2>/dev/null" 1
Execute .target.bash "/usr/sbin/config.postfix 2>/dev/null" 1
Return true
Dump RunSuSEconfigModule
Execute .target.bash "/sbin/SuSEconfig --module postfix" 0
Return true
Execute .target.bash "/sbin/SuSEconfig --module postfix" 1
Return false
Dump SetupSMPPPD
Return true
Return false
4 changes: 0 additions & 4 deletions testsuite/tests/runtime.ycp
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,6 @@ DUMP("RunSuSEconfig");
TEST(``(RunSuSEconfig()), [$[],$[],EXEC0], nil);
TEST(``(RunSuSEconfig()), [$[],$[],EXEC1], nil);

DUMP("RunSuSEconfigModule");
TEST(``(RunSuSEconfigModule("postfix")), [$[],$[],EXEC0], nil);
TEST(``(RunSuSEconfigModule("postfix")), [$[],$[],EXEC1], nil);

import "NetworkInterfaces";
NetworkInterfaces::Devices = $[ "dsl" : $[ "0" : $[] ]];

Expand Down