Chroot systemctl command for disable auto-update

Fixes: 255

We see build problems due to new releases of systemd, so
only use it in chroot versus the --root option.

Signed-off-by: Mark D Horn <mark.d.horn@intel.com>
This commit is contained in:
Mark D Horn
2019-03-06 18:22:25 -08:00
committed by Mark Horn
parent f424bdb143
commit 3ff5c00a50
+3 -3
View File
@@ -191,10 +191,10 @@ func (s *SoftwareUpdater) Update() error {
// See Issue https://github.com/clearlinux/swupd-client/issues/527
func (s *SoftwareUpdater) DisableUpdate() error {
args := []string{
filepath.Join(s.rootDir, "/usr/bin/systemctl"),
fmt.Sprintf("--root=%s", s.rootDir),
"chroot",
s.rootDir,
"systemctl",
"mask",
"--now",
"swupd-update.service",
"swupd-update.timer",
}