feat(tunable): add new system_user variable.

This commit is contained in:
Alexandre Pujol 2024-02-14 23:58:18 +00:00
parent e28e452ba4
commit e02bf03cca
Failed to generate hash of commit
2 changed files with 2 additions and 0 deletions

View file

@ -56,6 +56,7 @@
# Name of the systemd profile: unconfined || systemd
@{systemd}=unconfined
@{systemd_user}=unconfined
# Udev data dynamic assignment ranges
@{dynamic}=23[4-9] 24[0-9] 25[0-4] # range 234 to 254

View file

@ -206,6 +206,7 @@ func SetFullSystemPolicy() ([]string, error) {
return res, err
}
out := strings.Replace(string(content), "@{systemd}=unconfined", "@{systemd}=systemd", -1)
out = strings.Replace(out, "@{systemd_user}=unconfined", "@{systemd_user}=systemd-user", -1)
if err := path.WriteFile([]byte(out)); err != nil {
return res, err
}