solar-resources/resources/riak_node/1.0.0/actions/run.yaml
Jedrzej Nowak 1b28b8f3c4 Change resources structure to match repository one
Change-Id: Ie8d8c092e64890af2f0886303ef3f16752ba5b76
2015-12-18 18:01:20 +01:00

29 lines
742 B
YAML

- hosts: [{{host}}]
sudo: yes
tasks:
# those below are mostly for tests
- shell: killall -u riak
ignore_errors: yes
# remove above when non tests
# we install ubuntu repo there,
# NOT recommended on production
- shell: curl -s https://packagecloud.io/install/repositories/basho/riak/script.deb.sh | sudo bash
- apt:
name: riak
state: present
- service:
name: riak
state: stopped
- file: path=/etc/riak/riak.conf state=touch
- template:
src: {{templates_dir}}/riak.conf
dest: /etc/riak/riak.conf
- shell: rm -fr /var/lib/riak/kv_vnode/*
- shell: rm -fr /var/lib/riak/ring/*
- service:
name: riak
state: reloaded