This repository has been archived on 2020-09-27. You can view files and clone it, but cannot push or open issues or pull requests.
ansible-role-warehost/warehost-api/tasks/main.yml

26 lines
803 B
YAML
Raw Normal View History

2016-11-22 14:14:04 +01:00
---
2016-12-13 17:22:52 +01:00
- name: Download Warehost
2016-12-29 09:15:13 +01:00
get_url: url=https://warehost.sum7.eu/downloads/current/warehost-api dest=/usr/local/bin/warehost-api owner=root group=root mode=0755 force=yes
2016-12-20 12:14:13 +01:00
notify: restart warehost-api
2016-11-22 14:14:04 +01:00
- name: Configurate warehost
template: src=config.yml dest=/etc/warehost/api.conf owner=warehost mode=0600
2016-11-25 00:03:20 +01:00
notify: restart warehost-api
2016-11-22 14:14:04 +01:00
- name: Install service
2016-11-25 00:03:20 +01:00
template: src=warehost-api.unit dest=/lib/systemd/system/warehost-api.service owner=root mode=644
2016-11-22 14:14:04 +01:00
notify:
- reload daemon-reload
2016-11-25 00:03:20 +01:00
- restart warehost-api
2016-11-22 14:14:04 +01:00
- name: Enable warehost
2016-11-25 00:03:20 +01:00
service: name=warehost-api state=started enabled=yes
2016-11-22 14:14:04 +01:00
- name: Configurate per nginx
include: nginx.yml
when: warehost_webserver_type == "nginx"
- name: Configurate per caddy
include: caddy.yml
when: warehost_webserver_type == "caddy"