You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by is...@apache.org on 2013/08/26 06:40:35 UTC

git commit: Updated stratos installer to support jclouds upgrade and external message broker deployment

Updated Branches:
  refs/heads/master e60fa5964 -> 043e105a7


Updated stratos installer to support jclouds upgrade and external message broker deployment

Signed-off-by: Isuru Perera <is...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/incubator-stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-stratos/commit/043e105a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-stratos/tree/043e105a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-stratos/diff/043e105a

Branch: refs/heads/master
Commit: 043e105a71f861fdc3e0c5023f42237ac4eba58a
Parents: e60fa59
Author: Imesh Gunaratne <im...@wso2.com>
Authored: Sat Aug 24 07:59:07 2013 +0530
Committer: Isuru Perera <is...@apache.org>
Committed: Mon Aug 26 10:09:55 2013 +0530

----------------------------------------------------------------------
 tools/stratos-installer/conf/setup.conf         | 14 +++---
 .../cc/repository/conf/cloud-controller.xml     |  2 +-
 .../stratos-installer/config/sc/bin/stratos.sh  |  1 +
 .../config/sc/repository/conf/axis2/axis2.xml   |  4 +-
 .../repository/conf/cartridge-config.properties |  2 +-
 tools/stratos-installer/setup.sh                | 45 ++++++--------------
 6 files changed, 26 insertions(+), 42 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/conf/setup.conf
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/conf/setup.conf b/tools/stratos-installer/conf/setup.conf
index eb30d99..0064489 100644
--- a/tools/stratos-installer/conf/setup.conf
+++ b/tools/stratos-installer/conf/setup.conf
@@ -44,14 +44,16 @@ export host_user="" #A host user account for stratos. If not provided deafult is
 export mysql_connector_jar=$stratos_pack_path/"mysql-connector-java-5.1.25.jar" #mysql connector jar file name
 
 
+# MB configuration
+# ----------------------------------------------------------------------------
+export mb_hostname=stratos.apache.org
+export mb_listen_port="5677"
+
 
 # SC configuration
 # ----------------------------------------------------------------------------
 export sc_path=$stratos_path/"apache-stratos-sc-3.0.0-SNAPSHOT"
 export sc_pack=$stratos_pack_path/"apache-stratos-sc-3.0.0-SNAPSHOT.zip"
-#export lib_path="/opt/lib"
-#export script_path="/opt/scripts"
-#export resource_path="/opt/resources"
 
 export stratos2_domain="stratos.apache.org"
 
@@ -79,7 +81,6 @@ export agent_ip=$hostip
 
 # Billing configuration
 # ----------------------------------------------------------------------------
-
 #export billing_db_hostanme="stratos.apache.org"
 #export billing_db_username="root"
 #export billing_db_password="root"
@@ -104,7 +105,6 @@ export cc_path=$stratos_path/"apache-stratos-cc-3.0.0-SNAPSHOT"
 export cc_pack=$stratos_pack_path/"apache-stratos-cc-3.0.0-SNAPSHOT.zip"
 
 export cc_https_port="9444"
-export mb_listen_port="5673"
 export cc_port_offset=1
 export cc_hostname="stratos.apache.org"
 export mb_cassandra_host="localhost"
@@ -167,7 +167,7 @@ export openstack_identity="stratos:stratos" # Openstack project name:Openstack l
 export openstack_credential="password" # Openstack login password
 export openstack_tenant="stratos" # openstack project name
 export openstack_project_id=$openstack_tenant
-export openstack_jclouds_endpoint="http://10.100.0.30:5000/"
+export openstack_jclouds_endpoint="http://hostname:5000/v2.0"
 export openstack_scaleup_order=2
 export openstack_scaledown_order=3
 
@@ -176,7 +176,7 @@ export openstack_keypair_name="key-pair-name" #Name of the openstack key pair. T
 
 export openstack_image_id="RegionOne/" #No need to change this as of now
 export nova_region="RegionOne"
-export openstack_instance_type_tiny="RegionOne\/2"
+export openstack_instance_type_tiny="RegionOne\/1"
 export openstack_instance_type_small="RegionOne\/2"
 export openstack_security_group="security-group-name"
 export php_cartridge_image_id=""

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/config/cc/repository/conf/cloud-controller.xml
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/config/cc/repository/conf/cloud-controller.xml b/tools/stratos-installer/config/cc/repository/conf/cloud-controller.xml
index 4d25e5f..bab51ce 100644
--- a/tools/stratos-installer/config/cc/repository/conf/cloud-controller.xml
+++ b/tools/stratos-installer/config/cc/repository/conf/cloud-controller.xml
@@ -43,7 +43,7 @@
 
     	<topologySync enable="true">
 		<!-- MB server info -->
-		<property name="mbServerUrl" value="MB_HOSTNAME:MB_LISTEN_PORT" />
+		<property name="amqpConnectionUrl" value="amqp://admin:admin@clientID/carbon?brokerlist='tcp://MB_HOSTNAME:MB_LISTEN_PORT'" />
 		<property name="cron" value="1 * * * * ? *" />
 	</topologySync>	
 

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/config/sc/bin/stratos.sh
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/config/sc/bin/stratos.sh b/tools/stratos-installer/config/sc/bin/stratos.sh
index a095502..e00784f 100644
--- a/tools/stratos-installer/config/sc/bin/stratos.sh
+++ b/tools/stratos-installer/config/sc/bin/stratos.sh
@@ -293,6 +293,7 @@ do
     -Djava.security.egd=file:/dev/./urandom \
     -Dfile.encoding=UTF8 \
     -Dloadbalancer.conf=file:repository/conf/loadbalancer.conf \
+    -Dmb.server.ip=MB_HOSTNAME:MB_LISTEN_PORT \
     org.wso2.carbon.bootstrap.Bootstrap $*
     status=$?
 done

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/config/sc/repository/conf/axis2/axis2.xml
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/config/sc/repository/conf/axis2/axis2.xml b/tools/stratos-installer/config/sc/repository/conf/axis2/axis2.xml
index ecf49dd..3784f29 100644
--- a/tools/stratos-installer/config/sc/repository/conf/axis2/axis2.xml
+++ b/tools/stratos-installer/config/sc/repository/conf/axis2/axis2.xml
@@ -542,7 +542,7 @@
      corresponding to the "class" attribute of the "clustering" element. It is also responsible for
      getting this node to join the cluster.
      -->
-    <clustering class="org.apache.axis2.clustering.tribes.TribesClusteringAgent" enable="false">
+    <clustering class="org.apache.axis2.clustering.tribes.TribesClusteringAgent" enable="true">
 
         <!--
            This parameter indicates whether the cluster has to be automatically initalized
@@ -564,7 +564,7 @@
                     is deemed to have left the cluster, it will be detected by the Group Membership
                     Service (GMS) using a TCP ping mechanism.
         -->
-        <parameter name="membershipScheme">multicast</parameter>
+        <parameter name="membershipScheme">wka</parameter>
 
         <!--
          The clustering domain/group. Nodes in the same group will belong to the same multicast

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/config/sc/repository/conf/cartridge-config.properties
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/config/sc/repository/conf/cartridge-config.properties b/tools/stratos-installer/config/sc/repository/conf/cartridge-config.properties
index 7d8cc83..f0c4146 100644
--- a/tools/stratos-installer/config/sc/repository/conf/cartridge-config.properties
+++ b/tools/stratos-installer/config/sc/repository/conf/cartridge-config.properties
@@ -19,7 +19,7 @@ feature.internalrepo.enabled=false
 feature.multitenant.multiplesubscription.enabled=false
 
 
-mb.server.ip=CC_HOSTNAME:MB_LISTEN_PORT
+mb.server.ip=MB_HOSTNAME:MB_LISTEN_PORT
 
 append.script=SCRIPT_PATH/add_entry_zone_file.sh
 remove.script=SCRIPT_PATH/remove_entry_zone_file.sh

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/043e105a/tools/stratos-installer/setup.sh
----------------------------------------------------------------------
diff --git a/tools/stratos-installer/setup.sh b/tools/stratos-installer/setup.sh
index 19f0897..a6b8914 100755
--- a/tools/stratos-installer/setup.sh
+++ b/tools/stratos-installer/setup.sh
@@ -42,18 +42,18 @@ enable_internal_git=false
 
 function help {
     echo ""
-    echo "demo means you will setup a demo server of S2 in a single physical machine which has Openstack installed."
-    echo "This demo server include all S2 related packs."
+    echo "demo means you will setup a demo server of stratos in a single physical machine."
+    echo "This demo server include all stratos products."
     echo "usage:"
-    echo "setup.sh -u<host user name> -d<demo> -p\"<product list>\""
+    echo "setup.sh -u<host username> -d<demo> -p\"<product list>\""
     echo "eg."
-    echo "sudo JAVA_HOME=/opt/jdk1.6.0_24 ./setup.sh -dopenstack -p\"cc elb\""
-    echo "sudo JAVA_HOME=/opt/jdk1.6.0_24 ./setup.sh -dopenstack -p\"all\""
+    echo "sudo JAVA_HOME=<java-home> ./setup.sh -dopenstack -p\"cc elb\""
+    echo "sudo JAVA_HOME=<java-home> ./setup.sh -dopenstack -p\"all\""
     echo ""
     echo "-d: <demo name> whether you need to run demo for ec2 or openstack. The value is one of ec2|openstack. By default no demo is setup"
     echo "-p: <product list> Give one or more of the servers to be setup in this machine. The available servers are"
-    echo "-g: <enable_internal_git true|false> Whether enable internal git repo for Stratos2. Default is false"
     echo "    cc, elb, agent, sc or all. 'all' means you need to setup all servers in this machine. Default is all"
+    echo "-g: <enable_internal_git true|false> Whether enable internal git repo for Stratos2. Default is false"
     echo ""
 }
 
@@ -337,7 +337,7 @@ if [[ $sc = "true" ]]; then
 
     echo "Set mb hostname and mb port in bin/stratos.sh." >> $LOG
     cp -f ./bin/stratos.sh bin/stratos.sh.orig
-    cat bin/stratos.sh.orig | sed -e "s@CC_HOSTNAME:MB_LISTEN_PORT@$cc_hostname:$mb_listen_port@g" > bin/stratos.sh
+    cat bin/stratos.sh.orig | sed -e "s@MB_HOSTNAME:MB_LISTEN_PORT@$mb_hostname:$mb_listen_port@g" > bin/stratos.sh
 
     echo "Change CC hostname in repository/conf/cartridge-config.properties" >> $LOG
 
@@ -371,7 +371,7 @@ if [[ $sc = "true" ]]; then
     cat repository/conf/cartridge-config.properties.orig | sed -e "s@STRATOS_FOUNDATION_DB_SCHEMA@$stratos_foundation_db_schema@g" > repository/conf/cartridge-config.properties
 
     cp -f repository/conf/cartridge-config.properties repository/conf/cartridge-config.properties.orig
-    cat repository/conf/cartridge-config.properties.orig | sed -e "s@CC_HOSTNAME:MB_LISTEN_PORT@$cc_hostname:$mb_listen_port@g" > repository/conf/cartridge-config.properties
+    cat repository/conf/cartridge-config.properties.orig | sed -e "s@MB_HOSTNAME:MB_LISTEN_PORT@$mb_hostname:$mb_listen_port@g" > repository/conf/cartridge-config.properties
 
     cp -f repository/conf/cartridge-config.properties repository/conf/cartridge-config.properties.orig
     cat repository/conf/cartridge-config.properties.orig | sed -e "s@ELB_IP@$elb_ip@g" > repository/conf/cartridge-config.properties
@@ -534,10 +534,10 @@ if [[ $cc = "true" ]]; then
 #                </iaasProvider>
 #        </iaasProviders>
 
-   echo "Set openstack provider specific info on repository/conf/cloud-controller.xml" >> $LOG
 
    if [[ $ec2_provider_enable = "true" ]]; then
-
+       echo "Set EC2 provider specific info in repository/conf/cloud-controller.xml" >> $LOG
+       
        cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
        cat repository/conf/cloud-controller.xml.orig | sed -e "s@EC2_PROVIDER_START@@g" > repository/conf/cloud-controller.xml
 
@@ -576,20 +576,11 @@ if [[ $cc = "true" ]]; then
 
        cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
        cat repository/conf/cloud-controller.xml.orig | sed -e "s@OPENSTACK_PROVIDER_END@--@g" > repository/conf/cloud-controller.xml
-       
-       cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
-       cat repository/conf/cloud-controller.xml.orig | sed -e "s@MB_HOSTNAME@$cc_hostname@g" > repository/conf/cloud-controller.xml
-       
-       cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
-       cat repository/conf/cloud-controller.xml.orig | sed -e "s@MB_LISTEN_PORT@$mb_listen_port@g" > repository/conf/cloud-controller.xml
-
    fi
 
-    
-   echo "Set EC2 provider specific info on repository/conf/cloud-controller.xml" >> $LOG
-
    if [[ $openstack_provider_enable = "true" ]]; then
-
+       echo "Set OpenStack provider specific info in repository/conf/cloud-controller.xml" >> $LOG
+       
        cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
        cat repository/conf/cloud-controller.xml.orig | sed -e "s@OPENSTACK_PROVIDER_START@@g" > repository/conf/cloud-controller.xml
        
@@ -619,18 +610,10 @@ if [[ $cc = "true" ]]; then
 
        cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
        cat repository/conf/cloud-controller.xml.orig | sed -e "s@EC2_PROVIDER_END@--@g" > repository/conf/cloud-controller.xml
-
-
-       cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
-       cat repository/conf/cloud-controller.xml.orig | sed -e "s@MB_HOSTNAME@$cc_hostname@g" > repository/conf/cloud-controller.xml
-
-       cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
-       cat repository/conf/cloud-controller.xml.orig | sed -e "s@MB_LISTEN_PORT@$mb_listen_port@g" > repository/conf/cloud-controller.xml
-
    fi
 
     cp -f repository/conf/cloud-controller.xml repository/conf/cloud-controller.xml.orig
-    cat repository/conf/cloud-controller.xml.orig | sed -e "s@CC_HOSTNAME:MB_LISTEN_PORT@$cc_hostname:$mb_listen_port@g" > repository/conf/cloud-controller.xml
+    cat repository/conf/cloud-controller.xml.orig | sed -e "s@MB_HOSTNAME:MB_LISTEN_PORT@$mb_hostname:$mb_listen_port@g" > repository/conf/cloud-controller.xml
 
     echo "In repository/conf/carbon.xml"
     cp -f repository/conf/carbon.xml repository/conf/carbon.xml.orig
@@ -687,7 +670,7 @@ if [[ $elb = "true" ]]; then
     cat repository/conf/loadbalancer.conf.orig | sed -e "s@ENABLE_EMBEDDED_AUTOSCALER@$enable_embedded_autoscaler@g" > repository/conf/loadbalancer.conf
 
     cp -f repository/conf/loadbalancer.conf repository/conf/loadbalancer.conf.orig
-    cat repository/conf/loadbalancer.conf.orig | sed -e "s@MB_HOSTNAME:MB_LISTEN_PORT@$cc_hostname:$mb_listen_port@g" > repository/conf/loadbalancer.conf
+    cat repository/conf/loadbalancer.conf.orig | sed -e "s@MB_HOSTNAME:MB_LISTEN_PORT@$mb_hostname:$mb_listen_port@g" > repository/conf/loadbalancer.conf
 
     echo "Set hostname of the machine where elb run, in repository/conf/axis2/axis2.xml" >> $LOG
     #<!--parameter name="localMemberHost">ELB_HOSTNAME</parameter-->