This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
tsg-tsg-os-buildimage/init_runtime/roles/telegraf_statistic/tasks/main.yml
fumingwei 52c76ec953 1、增加初始化运行环境配置文件的部署脚本
2、修改与运行环境相关的配置文件的template文件模板名字
2021-05-10 19:14:32 +08:00

23 lines
646 B
YAML

- name: "copy telegraf.rpm to destination server"
copy:
src: "{{ role_path }}/files/telegraf-1.13.0-1.x86_64.rpm"
dest: /tmp
- name: "install telegraf"
yum:
name:
- /tmp/telegraf-1.13.0-1.x86_64.rpm
state: present
- name: "Templates telegraf.conf"
template:
src: "{{role_path}}/templates/telegraf_statistic.conf.j2.j2"
dest: /opt/tsg/init_runtime/roles/telegraf_statistic/templates/telegraf_statistic.conf.j2
tags: template
- name: "copy telegraf_statistic.service to destination server"
copy:
src: "{{ role_path }}/files/telegraf_statistic.service"
dest: /usr/lib/systemd/system
mode: 0644