summaryrefslogtreecommitdiffstats
path: root/roles/container_runtime/tasks/udev_workaround.yml
blob: 257c3123dcd4d7b1a6bb0303c3260ead4992fac9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
---

- name: Getting current systemd-udevd exec command
  command: grep -e "^ExecStart=" /lib/systemd/system/systemd-udevd.service
  changed_when: false
  register: udevw_udev_start_cmd

- name: Assure systemd-udevd.service.d directory exists
  file:
    path: "{{ udevw_udevd_dir }}"
    state: directory

- name: Create systemd-udevd override file
  copy:
    content: |
      [Service]
      #Need blank ExecStart to "clear" pre-existing one
      ExecStart=
      {{ udevw_udev_start_cmd.stdout }} --event-timeout=300
    dest: "{{ udevw_udevd_dir }}/override.conf"
    owner: root
    mode: "0644"
  notify:
    - restart udev