Skip to content

Commit

Permalink
[ansible/tuning] Set existing CPU governor configuration to performance
Browse files Browse the repository at this point in the history
  • Loading branch information
goldyfruit committed Dec 14, 2023
1 parent 5d890ed commit 242b89b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions ansible/roles/ovos_installer/tasks/tuning/governor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,18 @@
tags:
- always

- name: Check for existing CPU governor configuration
ansible.builtin.stat:
path: /etc/default/cpu_governor
register: _cpu_governor_config

- name: Set existing CPU governor to "performance"
ansible.builtin.lineinfile:
path: /etc/default/cpu_governor
regexp: '^CPU_DEFAULT_GOVERNOR='
line: 'CPU_DEFAULT_GOVERNOR="performance"'
when: _cpu_governor_config.stat.exists

- name: Copy cpu-governor systemd unit file
ansible.builtin.copy:
src: tuning/cpu-governor.service
Expand Down

0 comments on commit 242b89b

Please sign in to comment.