Skip to content

Commit 91f1d38

Browse files
committed
unixPB: adds become: true to all kernel config related tasks
in macos, touching `/etc/sysctl.conf`, puting content in it or rebooting system is what needs scallated priviledge because most of the time ansible user does not have enought authority to do system changes and need to use sudo. Adding `become: true` guarantee that ansible will not fail due to priviledge issue. Signed-off-by: [email protected]
1 parent 028773c commit 91f1d38

File tree

1 file changed

+4
-0
lines changed
  • ansible/playbooks/AdoptOpenJDK_Unix_Playbook/roles/Common/tasks

1 file changed

+4
-0
lines changed

ansible/playbooks/AdoptOpenJDK_Unix_Playbook/roles/Common/tasks/MacOSX.yml

+4
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@
212212
mode: 0644
213213
owner: root
214214
group: wheel
215+
become: true
215216
tags:
216217
- kernel_tuning
217218

@@ -222,6 +223,7 @@
222223
kern.sysv.shmmax=125839605760
223224
kern.sysv.shmall=30722560
224225
register: kernel
226+
become: true
225227
tags:
226228
- kernel_tuning
227229

@@ -232,6 +234,7 @@
232234
mode: 0774
233235
owner: root
234236
group: staff
237+
become: true
235238
tags:
236239
- core_dumps
237240

@@ -240,6 +243,7 @@
240243
reboot:
241244
reboot_timeout: 3600
242245
when: kernel.changed
246+
become: true
243247
tags:
244248
- kernel_tuning
245249
- skip_ansible_lint

0 commit comments

Comments
 (0)