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/ansible/roles/hasp/tasks/main.yml
2023-06-21 04:17:42 +00:00

52 lines
1.2 KiB
YAML

- name: "aksusbd rpm install: copy file to device"
copy:
src: '{{ role_path }}/files/aksusbd-8.23-1.x86_64.rpm'
dest: /tmp/ansible_deploy/
- name: "download rpm packages: hasp_tools"
yum:
name:
- "{{ hasp_tools_rpm_version.hasp_tools }}"
conf_file: "{{ rpm_repo_config_path }}"
state: present
download_only: yes
download_dir: "{{ path_download }}"
- name: "aksusbd rpm install: install aksusbd"
yum:
name:
- "/tmp/ansible_deploy/aksusbd-8.23-1.x86_64.rpm"
state: present
disable_gpg_check: yes
- name: "Get hasp_tools rpm path"
find:
path: /tmp/rpm_download/
pattern: "{{ hasp_tools_rpm_version.hasp_tools }}*"
register: hasp_tools_rpm_fullname
- name: "Install hasp_tools from local path"
yum:
name: "{{ hasp_tools_rpm_fullname.files[0].path }}"
state: present
disable_gpg_check: yes
- name: "Create /etc/tsg/licence/ directory if it does not exist"
file:
path: "{{ item }}"
state: directory
mode: '0755'
with_items:
- /etc/tsg/licence/
- name: "copy hasp.sh to /etc/profile.d/"
copy:
src: "{{ role_path }}/files/hasp.sh"
dest: /etc/profile.d/
mode: 0755
- name: "start hasp_monitor.service"
systemd:
name: hasp_monitor.service
enabled: yes