new transfer tasks and fixed permissions

This commit is contained in:
abrown38 committed 2025-03-21 14:13:13 +00:00
1 parent f1541c6f29
commit dc1afab15f
7 files changed
+122 -18

No files matched your search

+5 -9
View File
@@ -74,22 +74,18 @@
file_system: NTFS
new_label: "{{ filetransfer_volume_label }}"
- name: Create Import and Export directories in T drive for File Transfer script
- name: Create Import, Export, and Logs directories in T drive for File Transfer script
win_file:
path: "T:\\{{ item }}"
state: directory
with_items: ["Import", "Export"]
- name: Create logs directory in T drive
win_file:
path: "T:\\Logs"
state: directory
with_items: ["Import", "Export", "Logs"]
- name: Set permissions on logs folder on T drive
win_acl:
path: "T:\\logs"
user: file-transfer
path: "T:\\{{ item }}"
user: "{{ win_project }}\\{{ filetransfer_user }}"
type: allow
rights: Read,Write,Modify
state: present
with_items: ["Import", "Export", "Logs"]
when: inventory_hostname in groups['meta-name_fs01']
@@ -1,4 +1,12 @@
---
- name: add user rights to file-transfer user
tags: transfer_user_rights
ansible.windows.win_user_right:
name: SeBatchLogonRight
users:
- "{{ win_project }}\\{{ filetransfer_user }}"
action: add
- name: Copy scripts to fileserver
tags: copy_scheduled_tasks
block:
@@ -38,6 +46,9 @@
start_boundary: "{{ task_start_time.stdout }}"
repetition:
interval: PT5M
multiple_instances: 1
run_level: highest
start_when_available: true
- name: Create import scheduled task
win_scheduled_task:
@@ -55,4 +66,7 @@
start_boundary: "{{ task_start_time.stdout }}"
repetition:
interval: PT5M
multiple_instances: 1
run_level: highest
start_when_available: true
when: inventory_hostname in groups['meta-name_fs01']