mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-10-01 01:36:09 -04:00
bootstrapper: use systemd dbus connection
This commit is contained in:
parent
6f56ed69f8
commit
f92a07821e
@ -14,7 +14,7 @@ import (
|
||||
)
|
||||
|
||||
func startSystemdUnit(ctx context.Context, unit string) error {
|
||||
conn, err := dbus.NewSystemdConnectionContext(ctx)
|
||||
conn, err := dbus.NewSystemConnectionContext(ctx)
|
||||
if err != nil {
|
||||
return fmt.Errorf("establishing systemd connection: %w", err)
|
||||
}
|
||||
@ -38,7 +38,7 @@ func startSystemdUnit(ctx context.Context, unit string) error {
|
||||
}
|
||||
|
||||
func enableSystemdUnit(ctx context.Context, unitPath string) error {
|
||||
conn, err := dbus.NewSystemdConnectionContext(ctx)
|
||||
conn, err := dbus.NewSystemConnectionContext(ctx)
|
||||
if err != nil {
|
||||
return fmt.Errorf("establishing systemd connection: %w", err)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user