Skip to content

Commit c976e14

Browse files
authored
Merge pull request #601 from mbussolotto/enable_saline
saline container fails to start if server is not up and running
2 parents c091832 + f0f1f36 commit c976e14

3 files changed

Lines changed: 22 additions & 20 deletions

File tree

mgradm/cmd/install/podman/utils.go

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -117,25 +117,6 @@ func installForPodman(
117117
return err
118118
}
119119

120-
if err := coco.SetupCocoContainer(
121-
systemd, authFile, flags.Image.Registry, flags.Coco, flags.Image,
122-
flags.Installation.DB,
123-
); err != nil {
124-
return err
125-
}
126-
127-
if err := hub.SetupHubXmlrpc(
128-
systemd, authFile, flags.Image.Registry, flags.Image.PullPolicy, flags.Image.Tag, flags.HubXmlrpc,
129-
); err != nil {
130-
return err
131-
}
132-
133-
if err := saline.SetupSalineContainer(
134-
systemd, authFile, flags.Image.Registry, flags.Saline, flags.Image, flags.Installation.TZ,
135-
); err != nil {
136-
return err
137-
}
138-
139120
cnx := shared.NewConnection("podman", shared_podman.ServerContainerName, "")
140121
if err := podman.WaitForSystemStart(systemd, cnx, preparedImage, flags.Installation.TZ,
141122
flags.Installation.Debug.Java, flags.Mirror, flags.Podman.Args); err != nil {
@@ -155,6 +136,25 @@ func installForPodman(
155136
if err := shared_podman.EnablePodmanSocket(); err != nil {
156137
return utils.Error(err, L("cannot enable podman socket"))
157138
}
139+
140+
if err := coco.SetupCocoContainer(
141+
systemd, authFile, flags.Image.Registry, flags.Coco, flags.Image,
142+
flags.Installation.DB,
143+
); err != nil {
144+
return err
145+
}
146+
147+
if err := hub.SetupHubXmlrpc(
148+
systemd, authFile, flags.Image.Registry, flags.Image.PullPolicy, flags.Image.Tag, flags.HubXmlrpc,
149+
); err != nil {
150+
return err
151+
}
152+
153+
if err := saline.SetupSalineContainer(
154+
systemd, authFile, flags.Image.Registry, flags.Saline, flags.Image, flags.Installation.TZ,
155+
); err != nil {
156+
return err
157+
}
158158
return nil
159159
}
160160

shared/podman/systemd.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -386,5 +386,5 @@ func (s SystemdImpl) ScaleService(replicas int, name string) error {
386386
return utils.Errorf(err, L("cannot disable service"))
387387
}
388388
}
389-
return nil
389+
return s.RestartInstantiated(name)
390390
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
- Start saline containers and the other after
2+
server is running

0 commit comments

Comments
 (0)