Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ansible: become root when interacting with systemd #15

Merged
merged 1 commit into from
Nov 22, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ansible/roles/bench_app_service/handlers/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
- name: Start app
become: true
become_user: root
ansible.builtin.systemd_service:
name: ci-bench-runner
state: restarted
2 changes: 2 additions & 0 deletions ansible/roles/cpufreq/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -15,6 +15,8 @@
group: root
mode: u=rw,g=r,o=r
- name: Enable systemd service
become: true
become_user: root
ansible.builtin.systemd_service:
name: set-scaling-governor
state: started
2 changes: 2 additions & 0 deletions ansible/roles/nginx/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -25,6 +25,8 @@
dest: /etc/nginx/sites-enabled/{{ hostname }}.conf
mode: u=rw,g=r,o=r
- name: Reload nginx
become: true
become_user: root
ansible.builtin.systemd_service:
name: nginx
state: reloaded