airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lah...@apache.org
Subject [13/49] airavata git commit: Use fqdn instead of ip4 address in hosts file, removed redundent tags from rabbitmq and zookeeper
Date Sat, 01 Oct 2016 23:46:35 GMT
Use fqdn instead of ip4 address in hosts file, removed redundent tags from rabbitmq and zookeeper


Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/433ae48b
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/433ae48b
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/433ae48b

Branch: refs/heads/lahiru/AIRAVATA-2107
Commit: 433ae48bb6b38d850f64d3ce6392acd6c4fd8d64
Parents: 414c0e9
Author: Shameera Rathnayaka <shameerainfo@gmail.com>
Authored: Mon Aug 1 23:19:33 2016 -0400
Committer: Shameera Rathnayaka <shameerainfo@gmail.com>
Committed: Mon Aug 1 23:19:33 2016 -0400

----------------------------------------------------------------------
 group_vars/all                 |  6 +++---
 hosts                          | 12 ++++++------
 roles/rabbitmq/tasks/main.yml  | 14 +++++---------
 roles/zookeeper/tasks/main.yml |  2 --
 4 files changed, 14 insertions(+), 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/433ae48b/group_vars/all
----------------------------------------------------------------------
diff --git a/group_vars/all b/group_vars/all
index 6098bc1..bae52a5 100644
--- a/group_vars/all
+++ b/group_vars/all
@@ -34,15 +34,15 @@ key_stores_location: "{{ deployment_dir }}/keystores"
 mysql_connector_jar: "mysql-connector-java-5.1.37-bin.jar"
 
 api_server_name: "apiserver-node0"
-api_server_host: "{{ host_address }}"
+api_server_host: "{{ ansible_fqdn }}"
 api_server_port: "8930"
 
 orchestrator_name: "orchestrator-node0"
-orchestrator_host: "{{ host_address }}"
+orchestrator_host: "{{ ansible_fqdn }}"
 orchestrator_port: "8940"
 
 gfac_name: "gfac-node0"
-gfac_host: "{{ host_address }}"
+gfac_host: "{{ ansible_fqdn }}"
 gfac_port: "8950"
 
 monitor_email_address: "jobs@scigap.org"

http://git-wip-us.apache.org/repos/asf/airavata/blob/433ae48b/hosts
----------------------------------------------------------------------
diff --git a/hosts b/hosts
index 2865ff1..8a317b8 100644
--- a/hosts
+++ b/hosts
@@ -2,24 +2,24 @@
 
 [api-orch]
 #149.165.156.196 host_name=js-156-196 host_address=149.165.156.196
-149.165.171.11 host_name=js-171-11 host_address=149.165.171.11
+js-171-11.jetstream-cloud.org
 
 [gfac]
 #149.165.156.196 host_name=js-156-196 host_address=149.165.156.196
-149.165.171.11 host_name=js-171-11 host_address=149.165.171.11
+js-171-11.jetstream-cloud.org
 
 [pga]
 #149.165.156.196
-149.165.171.11
+js-171-11.jetstream-cloud.org
 
 [zookeeper]
 #149.165.156.196 host_name=js-156-196 host_address=149.165.156.196
-149.165.171.11 host_name=js-171-11 host_address=149.165.171.11
+js-171-11.jetstream-cloud.org
 
 [rabbitmq]
 #149.165.156.196 host_name=js-156-196 host_address=149.165.156.196
-149.165.171.11 host_name=js-171-11 host_address=149.165.171.11
+js-171-11.jetstream-cloud.org
 
 [database]
 #149.165.156.196
-149.165.171.11
+js-171-11.jetstream-cloud.org

http://git-wip-us.apache.org/repos/asf/airavata/blob/433ae48b/roles/rabbitmq/tasks/main.yml
----------------------------------------------------------------------
diff --git a/roles/rabbitmq/tasks/main.yml b/roles/rabbitmq/tasks/main.yml
index 1d0647b..56ae071 100644
--- a/roles/rabbitmq/tasks/main.yml
+++ b/roles/rabbitmq/tasks/main.yml
@@ -5,31 +5,28 @@
 # Setup and run rabbitmq
 - name: Install erlang latest version
   yum: name=https://www.rabbitmq.com/releases/erlang/erlang-18.3-1.el7.centos.x86_64.rpm
state=present
-  tags: rabbitmq, dependency
-
 
 - name: Install Rabbitmq rpm
   yum: name=https://www.rabbitmq.com/releases/rabbitmq-server/v3.6.3/rabbitmq-server-3.6.3-1.noarch.rpm
state=present
-  tags: rabbimq, dependency
 
   # add hostname to /etc/hosts file
+- name: get ip4 address
+  command: dig +short myip.opendns.com @resolver1.opendns.com
+  register: _ip4
+
 - name: Edit /etc/hosts file
-  lineinfile: dest=/etc/hosts line="{{ host_address }} {{host_name}}"
+  lineinfile: dest=/etc/hosts line="{{ _ip4.stdout }} {{ ansible_hostname }} {{ ansible_fqdn
}}"
   notify:
     - restart rabbitmq
-  tags: rabbitmq, dependency
 
 - name: Start Rabbitmq server
   service: name=rabbitmq-server state=started
-  tags: rabbitmq, dependency
 
 - name: Enable rabbitmq management plugin
   rabbitmq_plugin: names=rabbitmq_management state=enabled
-  tags: rabbitmq, dependency
 
 - name: Create rabbitmq vhost {{ rabbitmq_vhost }}
   rabbitmq_vhost: name="{{ rabbitmq_vhost }}" state=present
-  tags: rabbitmq, dependency
 
 - name: Add user {{ rabbitmq_user }} to vhost {{ rabbitmq_vhost }}  and give permission
   rabbitmq_user: user="{{ rabbitmq_user }}"
@@ -39,6 +36,5 @@
                  read_priv=.*
                  write_priv=.*
                  state=present
-  tags: rabbitmq, dependency
 
 ...

http://git-wip-us.apache.org/repos/asf/airavata/blob/433ae48b/roles/zookeeper/tasks/main.yml
----------------------------------------------------------------------
diff --git a/roles/zookeeper/tasks/main.yml b/roles/zookeeper/tasks/main.yml
index c1fd86b..90a2d30 100644
--- a/roles/zookeeper/tasks/main.yml
+++ b/roles/zookeeper/tasks/main.yml
@@ -3,13 +3,11 @@
 # Setup and run Zookeeper
 - name: Download and unarchive zookeeper
   unarchive: src="{{ zookeeper_url }}" dest="{{ user_home }}" copy=no owner="{{ user }}"
group="{{ group }}"
-  tags: zookeeper, dependency
 
 - name: Copy zoo.cfg file
   template: src=zoo.cfg.j2 dest="{{ zookeeper_dir }}/conf/zoo.cfg" owner="{{ user }}" group="{{
group }}" mode="u=rw,g=r,o=r"
   notify:
     - start zookeeper
     - restart zookeeper
-  tags: zookeeper, dependency
 
 ...


Mime
View raw message