d4science-ghn-cluster/cassandra.yml: Add roles to install ganglia and nagios. Enable iptables.
d4science-ghn-cluster/group_vars/cassandra_dev/iptables.yml, d4science-ghn-cluster/group_vars/cassandra_prod/iptables.yml: iptables rules. library/roles/cassandra/defaults/main.yml: Enable cassandra at boot time by default.
This commit is contained in:
parent
433bb8e7cb
commit
97782273f9
|
@ -2,8 +2,13 @@
|
||||||
cassandra_install_from_external_repo: True
|
cassandra_install_from_external_repo: True
|
||||||
cassandra_install_packages: True
|
cassandra_install_packages: True
|
||||||
cassandra_latest_version: True
|
cassandra_latest_version: True
|
||||||
cassandra_start_server: 'no'
|
cassandra_start_server: True
|
||||||
cassandra_cluster_enabled: False
|
cassandra_cluster_enabled: False
|
||||||
|
cassandra_cluster_port: 7000
|
||||||
|
cassandra_cluster_ssl_port: 7001
|
||||||
|
cassandra_native_transport_port: 9042
|
||||||
|
cassandra_rpc_port: 9160
|
||||||
|
cassandra_jmx_port: 7199
|
||||||
cassandra_allowed_hosts:
|
cassandra_allowed_hosts:
|
||||||
- 127.0.0.1/8
|
- 127.0.0.1/8
|
||||||
- '{{ ansible_default_ipv4.address }}/32'
|
- '{{ ansible_default_ipv4.address }}/32'
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
---
|
---
|
||||||
- name: Update apt cache
|
|
||||||
apt: update_cache=yes
|
|
||||||
ignore_errors: true
|
|
||||||
|
|
||||||
- name: Restart cassandra
|
- name: Restart cassandra
|
||||||
service: name=cassandra state=restarted
|
service: name=cassandra state=restarted
|
||||||
|
when: cassandra_start_server
|
||||||
|
|
||||||
|
|
|
@ -5,15 +5,8 @@
|
||||||
tags: cassandra
|
tags: cassandra
|
||||||
|
|
||||||
- name: Install the cassandra repository
|
- name: Install the cassandra repository
|
||||||
copy: content="deb http://debian.datastax.com/community stable main" dest=/etc/apt/sources.list.d/cassandra.sources.list owner=root group=root mode=044
|
copy: content="deb http://debian.datastax.com/community stable main" dest=/etc/apt/sources.list.d/cassandra.sources.list owner=root group=root mode=0444 update_cache=yes
|
||||||
when: cassandra_install_from_external_repo
|
when: cassandra_install_from_external_repo
|
||||||
register: external_repo
|
|
||||||
tags: cassandra
|
|
||||||
|
|
||||||
- name: Update the apt cache
|
|
||||||
apt: update_cache=yes
|
|
||||||
when: ( external_repo | changed )
|
|
||||||
ignore_errors: True
|
|
||||||
tags: cassandra
|
tags: cassandra
|
||||||
|
|
||||||
- name: Install a specific version of cassandra server
|
- name: Install a specific version of cassandra server
|
||||||
|
@ -58,13 +51,13 @@
|
||||||
- cassandra_latest_version
|
- cassandra_latest_version
|
||||||
tags: cassandra
|
tags: cassandra
|
||||||
|
|
||||||
- name: Ensure cassandra is started
|
- name: Ensure cassandra is started and enabled
|
||||||
service: name=cassandra state=started enabled=yes
|
service: name=cassandra state=started enabled=yes
|
||||||
when: ( cassandra_start_server is defined ) and ( cassandra_start_server == 'yes' )
|
when: cassandra_start_server
|
||||||
tags: cassandra
|
tags: cassandra
|
||||||
|
|
||||||
- name: Ensure cassandra is stopped and disabled
|
- name: Ensure cassandra is stopped and disabled
|
||||||
service: name=cassandra state=stopped enabled=no
|
service: name=cassandra state=stopped enabled=no
|
||||||
when: ( cassandra_start_server is defined ) and ( cassandra_start_server == 'no' )
|
when: not cassandra_start_server
|
||||||
tags: cassandra
|
tags: cassandra
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue