mirror of
https://github.com/iiab/iiab.git
synced 2025-02-13 11:42:08 +00:00
47 lines
1.3 KiB
YAML
47 lines
1.3 KiB
YAML
- name: copy wshaper service script
|
|
template: backup=yes
|
|
src=wondershaper/wondershaper.service
|
|
dest=/etc/systemd/system/wondershaper.service
|
|
mode=0644
|
|
|
|
- name: copy wshaper script
|
|
template: backup=yes
|
|
src=wondershaper/wondershaper.j2
|
|
dest=/usr/bin/wondershaper
|
|
owner=root
|
|
group=root
|
|
mode=0744
|
|
|
|
- name: create conf.d directory
|
|
file: path=/etc/conf.d
|
|
owner=root
|
|
group=root
|
|
mode=0755
|
|
state=directory
|
|
|
|
- name: copy wshaper config script
|
|
template: src=wondershaper/wondershaper.conf
|
|
dest=/etc/conf.d/wondershaper.conf
|
|
owner=root
|
|
group=root
|
|
mode=0600
|
|
|
|
- name: create fact for wondershaper config file
|
|
file: src=/etc/conf.d/wondershaper.conf
|
|
dest=/etc/ansible/facts.d/wondershaper.fact
|
|
owner=root
|
|
group=root
|
|
state=link
|
|
|
|
- name: Add wondershaper to service list
|
|
ini_file: dest='{{ service_filelist }}'
|
|
section=wondershaper
|
|
option='{{ item.option }}'
|
|
value='{{ item.value }}'
|
|
with_items:
|
|
- option: name
|
|
value: wondershaper
|
|
- option: description
|
|
value: '"Wondershaper is a command line tool to set maximum transfer rates for network adapters"'
|
|
- option: enabled
|
|
value: "{{ wondershaper_enabled }}"
|