summaryrefslogtreecommitdiff
path: root/roles/tsg-cli-mcn2/tasks/main.yml
blob: 434209a6d3d4a5c65d7784e181357b2bbd001ef1 (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
---
- name: "copy tsg-cli rmp to destination server"
  synchronize:
    src: "{{ role_path }}/../tsg-common-files/{{ rpm_file_name }}"
    dest: "/tmp/tsg-cli-deploy/"
    
- name: "install tsg-cli"
  yum:
    name: "{{ packages }}"
    state: present
  vars:
    packages:
    - /tmp/tsg-cli-deploy/{{ rpm_file_name }}

- name: Template the tsg_sn.json
  template:
    src: "{{ role_path }}/templates/tsg_sn.json.j2"
    dest: /opt/tsg/etc/tsg_sn.json
  tags: template
  
- name: "copy tsg-monitor.service to destination server"
  synchronize:
    src: "{{ role_path }}/files/tsg-monitor.service"
    dest: "/usr/lib/systemd/system"

- name: "copy tsg_chassis_interface.json to destination server"
  synchronize:
    src: "{{ role_path }}/files/tsg_chassis_interface.json"
    dest: "/opt/tsg/etc/"

- name: "copy tsg-monitor.sh to destination server"
  #synchronize:
  copy:
    src: "{{ role_path }}/files/tsg-monitor.sh"
    dest: "/opt/tsg/tsg-monitor/"    
    mode: 0755  
  
- name: "enable tsg-monitor service"
  systemd:
    name: tsg-monitor
    enabled: yes
    daemon_reload: yes

- name: "copy rsyslog.conf to destination server"
  synchronize:
    src: "{{ role_path }}/files/rsyslog.conf"
    dest: "/etc/"