Kenneth Benzie (Benie) 06b511d823 Set the owner of Git repos on Windows
The `win_git` module clones repos as the current user, which since its
an admin login is the admin. This patch adjusts the `win_owner` to so
that repos are owned by the correct user when being used in a non-admin
capacity.
2022-09-10 16:18:21 +01:00

37 lines
849 B
YAML

---
- name: install chocolatey package
win_chocolatey:
name: autohotkey
state: latest
- name: clone config repo
win_git:
repo: git@code.infektor.net:config/AutoHotKey.git
dest: '{{autohotkey_repo_dir}}'
branch: master
- win_owner:
path: '{{autohotkey_repo_dir}}'
user: Benie
- name: create scheduled task
win_scheduled_task:
path: Benie
name: macOS.ahk
state: present
enable: true
triggers:
- type: logon
enabled: true
- type: registration
enabled: true
actions:
- path: '{{autohotkey_repo_dir}}/macOS.ahk'
disallow_start_if_on_batteries: false
stop_if_going_on_batteries: false
execution_time_limit: PT0S
logon_type: interactive_token
multiple_instances: 3
run_level: highest
start_when_available: true
wake_to_run: false