Infra: AWS Update to Ubuntu 20.04
[csit.git] / resources / tools / testbed-setup / ansible / roles / performance_tuning / tasks / turbo_boost.yaml
1 ---
2 # file: roles/performance_tuning/tasks/turbo_boost.yaml
3
4 - name: Inst - Update Package Cache (APT)
5   apt:
6     update_cache: yes
7     cache_valid_time: 3600
8   when:
9     - ansible_distribution|lower == 'ubuntu'
10   tags:
11     - turbo-inst-prerequisites
12
13 - name: Inst - msr-tools
14   package:
15     name:
16       - "msr-tools"
17     state: latest
18   tags:
19     - turbo-inst-prerequisites
20
21 - name: Conf - Load msr By Default
22   lineinfile:
23     path: "/etc/modules"
24     state: "present"
25     line: "msr"
26   tags:
27     - turbo-conf-msr
28
29 - name: Conf - Custom Startup Service Hook
30   copy:
31     src: "files/disable-turbo-boost.service"
32     dest: "/etc/systemd/system/disable-turbo-boost.service"
33     owner: "root"
34     group: "root"
35     mode: 0644
36   tags:
37     - turbo-conf-msr
38
39 - name: Conf - Custom Startup Service Hook Enable
40   service:
41     name: "disable-turbo-boost"
42     enabled: yes
43   tags:
44     - turbo-conf-msr