Skip to content
Snippets Groups Projects
Commit 69fa6320 authored by Rafael Soares's avatar Rafael Soares
Browse files

Setting up authorization rule for Polkit

parent 46f1cb4c
No related branches found
No related tags found
No related merge requests found
......@@ -12,6 +12,15 @@ echo -e 'vagrant\nvagrant' | passwd
useradd -m -U vagrant
echo -e 'vagrant\nvagrant' | passwd vagrant
# setting automatic authentication for any action requiring admin rights via Polkit
cat <<EOF > /etc/polkit-1/rules.d/49-nopasswd_global.rules
polkit.addRule(function(action, subject) {
if (subject.isInGroup("vagrant")) {
return polkit.Result.YES;
}
});
EOF
# setting sudo for vagrant user
cat <<EOF > /etc/sudoers.d/vagrant
Defaults:vagrant !requiretty
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment