ansible/roles/ansible-pull/templates/ansible-pull.service

20 lines
586 B
Desktop File

# vim:ft=dosini:
[Unit]
Description=Ansible pull service
StartLimitIntervalSec=3600
StartLimitBurst=5
After=network-online.target
Wants=network-online.target
[Service]
User=ansible
Group=ansible
Type=oneshot
Environment=ANSIBLE_CONFIG=~/ansible-pull-repo/ansible-pull.cfg
ExecStart=ansible-pull --accept-host-key -U "{{ ansible_pull_repo }}" -C "{{ ansible_pull_commit }}" -d "~/ansible-pull-repo" --vault-password-file "~/ansiblevaultpass" "{{ ansible_pull_playbook }}" --skip-tags "{{ ansible_pull_skip_tags }}"
Restart=on-failure
RestartSec=90
[Install]
WantedBy=multi-user.target