summaryrefslogtreecommitdiff
path: root/roles/ick-worker/tasks/main.yml
blob: df26d167772880df3aa229543be7580673f8a2e0 (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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
- name: install ick worker manager
  apt:
    name: "{{ item }}"
  with_items:
    - "{{ ick_prefix }}ick2"
    - debootstrap
    - jq
    - less
    - htop
    - locales-all
    - systemd-container
    - git
    - rsync
    - dput

- name: create config dirs
  file:
    state: directory
    path: "{{ item }}"
    owner: root
    group: root
    mode: 0755
  with_items:
    - /etc/ick

- name: install worker-manager config
  template:
    src: worker_manager.yaml.j2
    dest: /etc/ick/worker_manager.yaml
    owner: root
    group: root
    mode: 0644

- name: install dput config
  template:
    src: dput.cf.j2
    dest: /etc/dput.cf
    owner: root
    group: root
    mode: 0644

- name: enable and start units
  systemd:
    daemon_reload: yes
    name: "{{ item }}"
    state: restarted
    enabled: yes
  with_items:
    - ick-worker

- name: configure ssh client with StrictHostKeyChecking=no
  lineinfile:
    dest: /etc/ssh/ssh_config
    state: present
    line: "StrictHostKeyChecking no"