Commit e75c6f13 authored by Ross McDonald's avatar Ross McDonald
Browse files

Modified status check. Moved start_service variable to vars file (over defaults).

parent 2b5be722
......@@ -2,14 +2,11 @@
# Channel of InfluxDB to install (stable, unstable, nightly)
influxdb_install_version: stable
# If yes, service will be started. Will not be started if set to no.
influxdb_start_service: yes
# If multiple servers are specified, whether to create a clustered configuration
# NOTE:
# - Do not attempt to cluster previously-unclustered servers. This can lead to data loss.
# - This will overwrite your /etc/default/influxdb file (though it makes a backup)
influxdb_cluster_servers: yes
influxdb_cluster_servers: no
# When clustering is enabled, whether or not to overwrite the /etc/hosts file with raw
# IPs (may be useful if no DNS resolution).
influxdb_overwrite_hosts_file: yes
......
......@@ -42,9 +42,10 @@
command: service influxdb status
register: influxdb_service_status
when: influxdb_start_service
ignore_errors: yes
- name: Assert status of InfluxDB service
assert:
that:
- "influxdb_service_status.rc == 0"
when: influxdb_start_service
\ No newline at end of file
when: influxdb_start_service
......@@ -3,5 +3,9 @@
# Whether or not the playbook is run locally (changes clustering logic slightly)
is_vagrant: no
# Whether or not to purge peer data on each run (useful for cluster testing)
influxdb_purge_peer_data: no
\ No newline at end of file
# Whether or not to purge peer data on each run (useful for cluster testing),
# NOTE: This will cause data loss on an active cluster, so use caution
influxdb_purge_peer_data: no
# If yes, service will be started. Will not be started if set to no.
influxdb_start_service: yes
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment