Skip to content

Commit e717584

Browse files
authored
Merge pull request #587 from mbussolotto/saline
fix several bugs related to saline service (bsc#1243329) (bsc#1243359)
2 parents 99574df + 30ae2b1 commit e717584

File tree

6 files changed

+12
-7
lines changed

6 files changed

+12
-7
lines changed

mgradm/cmd/scale/scale.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// SPDX-FileCopyrightText: 2024 SUSE LLC
1+
// SPDX-FileCopyrightText: 2025 SUSE LLC
22
//
33
// SPDX-License-Identifier: Apache-2.0
44

@@ -28,8 +28,9 @@ func newCmd(globalFlags *types.GlobalFlags, run utils.CommandFunc[scaleFlags]) *
2828
Short: L("Adjust the replicas for services supporting it."),
2929
Long: L(`Adjust the replicas for services supporting it.
3030
Supported services:
31-
- uyuni-server-attestation
3231
- uyuni-hub-xmlrpc
32+
- uyuni-saline
33+
- uyuni-server-attestation
3334
`),
3435
Args: cobra.ExactArgs(1),
3536
RunE: func(cmd *cobra.Command, args []string) error {

mgradm/cmd/uninstall/podman.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ func uninstallForPodman(
2525
images := []string{
2626
podman.GetServiceImage(podman.ServerService),
2727
podman.GetServiceImage(podman.ServerAttestationService + "@"),
28-
podman.GetServiceImage(podman.HubXmlrpcService),
29-
podman.GetServiceImage(podman.SalineService),
28+
podman.GetServiceImage(podman.HubXmlrpcService + "@"),
29+
podman.GetServiceImage(podman.SalineService + "@"),
3030
podman.GetServiceImage(podman.DBService),
3131
}
3232

@@ -37,7 +37,7 @@ func uninstallForPodman(
3737

3838
systemd.UninstallInstantiatedService(podman.ServerAttestationService, !flags.Force)
3939
systemd.UninstallInstantiatedService(podman.HubXmlrpcService, !flags.Force)
40-
systemd.UninstallService(podman.SalineService, !flags.Force)
40+
systemd.UninstallInstantiatedService(podman.SalineService, !flags.Force)
4141
systemd.UninstallService(podman.DBService, !flags.Force)
4242

4343
// Remove the volumes

mgradm/shared/podman/startstop.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ func StartServices() error {
1414
systemd.StartService(podman.DBService),
1515
systemd.StartInstantiated(podman.ServerAttestationService),
1616
systemd.StartInstantiated(podman.HubXmlrpcService),
17+
systemd.StartInstantiated(podman.SalineService),
1718
systemd.StartService(podman.ServerService),
1819
)
1920
}
@@ -22,6 +23,7 @@ func StopServices() error {
2223
return utils.JoinErrors(
2324
systemd.StopInstantiated(podman.ServerAttestationService),
2425
systemd.StopInstantiated(podman.HubXmlrpcService),
26+
systemd.StopInstantiated(podman.SalineService),
2527
systemd.StopService(podman.ServerService),
2628
systemd.StopService(podman.DBService),
2729
)

mgradm/shared/saline/saline.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ func writeSalineServiceFiles(
107107
config := fmt.Sprintf(`Environment=TZ=%s
108108
`, strings.TrimSpace(tz))
109109

110-
if err := podman.GenerateSystemdConfFile(podman.SalineService, "custom.conf",
110+
if err := podman.GenerateSystemdConfFile(podman.SalineService+"@", "custom.conf",
111111
config, false); err != nil {
112112
return utils.Error(err, L("cannot generate systemd user configuration file"))
113113
}

shared/podman/systemd.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ func (s SystemdImpl) UninstallService(name string, dryRun bool) {
111111
} else {
112112
log.Info().Msgf(L("Disable %s service"), name)
113113
// disable server
114-
err := utils.RunCmd("systemctl", "disable", "--now", name)
114+
err := s.DisableService(name)
115115
if err != nil {
116116
log.Error().Err(err).Msgf(L("Failed to disable %s service"), name)
117117
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
- fix several bugs related to saline service (bsc#1243329)
2+
- purge saline and hubxmlrpc image (bsc#1243359)

0 commit comments

Comments
 (0)