Skip to content

Commit

Permalink
cgroups_linux: use SessionBusPrivateNoAutoStartup
Browse files Browse the repository at this point in the history
port Commit 12a939e (cgroups: use SessionBusPrivateNoAutoStartup)
from cgroups.go to cgroups_linux.go

do not start up a dbus daemon if it is not already running.

[NO NEW TESTS NEEDED] the fix is in a dependency.

Signed-off-by: Joni Korhonen <[email protected]>
  • Loading branch information
jontte75 committed Aug 15, 2023
1 parent b70b0c4 commit 8986ad4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/cgroups/cgroups_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ func (c *CgroupControl) CreateSystemdUnit(path string) error {
// GetUserConnection returns an user connection to D-BUS
func GetUserConnection(uid int) (*systemdDbus.Conn, error) {
return systemdDbus.NewConnection(func() (*dbus.Conn, error) {
return dbusAuthConnection(uid, dbus.SessionBusPrivate)
return dbusAuthConnection(uid, dbus.SessionBusPrivateNoAutoStartup)
})
}

Expand Down

0 comments on commit 8986ad4

Please sign in to comment.