·Merge branch 'feature/selinux_setup'

This commit is contained in:
Bernd Schoolmann 2023-12-21 12:57:13 +01:00
commit 55b3383fb9
No known key found for this signature in database
1 changed files with 10 additions and 0 deletions

View File

@ -39,6 +39,16 @@ func setupPolkit() {
panic(err) panic(err)
} }
command3 := exec.Command("sudo", "chcon", "system_u:object_r:usr_t:s0", "/usr/share/polkit-1/actions/com.quexten.goldwarden.policy")
err = command3.Run()
if err != nil {
fmt.Println("failed setting selinux context")
fmt.Println(err.Error())
} else {
fmt.Println("Set selinux context successfully")
fmt.Println("Might require a reboot to take effect!")
}
fmt.Println("Polkit setup successfully") fmt.Println("Polkit setup successfully")
} }