You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by ud...@apache.org on 2015/06/04 11:20:44 UTC
[1/7] stratos git commit: Adding init.sh config.sh for openstack
Repository: stratos
Updated Branches:
refs/heads/master c14c6b16e -> 175a57a7d
Adding init.sh config.sh for openstack
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/6ff689f8
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/6ff689f8
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/6ff689f8
Branch: refs/heads/master
Commit: 6ff689f85b4ec5c3ccfce43c32e2f02f15a2d056
Parents: 2fe84b9
Author: anuruddhal <an...@gmail.com>
Authored: Wed Jun 3 18:00:16 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Wed Jun 3 18:00:16 2015 +0530
----------------------------------------------------------------------
tools/config-scripts/openstack/config.sh | 104 ++++++++++++++
tools/init-scripts/openstack/centos/init.sh | 147 ++++++++++++++++++++
tools/init-scripts/openstack/ubuntu/init.sh | 165 +++++++++++++++++++++++
3 files changed, 416 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/6ff689f8/tools/config-scripts/openstack/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/openstack/config.sh b/tools/config-scripts/openstack/config.sh
new file mode 100755
index 0000000..4ac4707
--- /dev/null
+++ b/tools/config-scripts/openstack/config.sh
@@ -0,0 +1,104 @@
+#!/bin/bash
+# --------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# --------------------------------------------------------------
+shopt -s nocasematch
+ECHO=`which echo`
+RM=`which rm`
+READ=`which read`
+TR=`which tr`
+HEAD=`which head`
+WGET=`which wget`
+MKDIR=`which mkdir`
+GREP=`which grep`
+SED=`which sed`
+CP=`which cp`
+MV=`which mv`
+
+HOSTSFILE=/etc/hosts
+LOCKFILE=/mnt/apache-stratos-cartridge-agent-4.0.0/wso2carbon.lck
+DATE=`date +%d%m%y%S`
+RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
+
+function valid_ip()
+{
+ local ip=$1
+ local stat=1
+
+ if [[ $ip =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then
+ OIFS=$IFS
+ IFS='.'
+ ip=($ip)
+ IFS=$OIFS
+ [[ ${ip[0]} -le 255 && ${ip[1]} -le 255 \
+ && ${ip[2]} -le 255 && ${ip[3]} -le 255 ]]
+ stat=$?
+ fi
+ return $stat
+}
+
+read -p "This script will install and configure puppet agent, do you want to continue [y/n]" answer
+if [[ $answer = y ]] ; then
+
+ ${CP} -f ${HOSTSFILE} /etc/hosts.tmp
+ ${MKDIR} -p /tmp/payload
+ ${WGET} http://169.254.169.254/latest/user-data -O /tmp/payload/launch-params
+
+ read -p "Please provide stratos service-name:" SERVICE_NAME
+ if [[ -z $SERVICE_NAME ]]; then
+ echo "service is empty!. Base image will be created."
+ SERVICE_NAME=default
+ fi
+
+ read -p "Please provide puppet master IP:" PUPPET_IP
+ if ! valid_ip $PUPPET_IP ; then
+ echo "invalid IP address format!"
+ exit -1
+ fi
+
+ read -p "Please provide puppet master hostname [puppet.stratos.org]:" DOMAIN
+ DOMAIN=${DOMAIN:-puppet.stratos.org}
+ #essential to have PUPPET_HOSTNAME at the end in order to auto-sign the certs
+
+ #read -p "Please provide stratos deployment:" DEPLOYMENT
+ #DEPLOYMENT=${DEPLOYMENT:-default}
+ DEPLOYMENT="default"
+
+ NODEID="${RANDOMNUMBER}.${DEPLOYMENT}.${SERVICE_NAME}"
+
+ ${ECHO} -e "\nNode Id ${NODEID}\n"
+ ${ECHO} -e "\nDomain ${DOMAIN}\n"
+
+ ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
+ ${ECHO} "\nRunning puppet installation with arguments: ${ARGS[@]}"
+ /root/bin/puppetinstall/puppetinstall "${ARGS[@]}"
+ #check for java agent lock file
+ if [ -e ${LOCKFILE} ]; then
+ ${RM} ${LOCKFILE}
+ fi
+
+ ${GREP} -q '/root/bin/init.sh > /tmp/puppet_log' /etc/rc.local || ${SED} -i 's/exit 0$/\/root\/bin\/init.sh \> \/tmp\/puppet_log\nexit 0/' /etc/rc.local
+ ${RM} -rf /tmp/*
+ ${RM} -rf /var/lib/puppet/ssl/*
+ ${MV} -f /etc/hosts.tmp ${HOSTSFILE}
+
+fi
+
+# END
http://git-wip-us.apache.org/repos/asf/stratos/blob/6ff689f8/tools/init-scripts/openstack/centos/init.sh
----------------------------------------------------------------------
diff --git a/tools/init-scripts/openstack/centos/init.sh b/tools/init-scripts/openstack/centos/init.sh
new file mode 100644
index 0000000..bc2aa4b
--- /dev/null
+++ b/tools/init-scripts/openstack/centos/init.sh
@@ -0,0 +1,147 @@
+#!/bin/bash
+# --------------------------------------------------------------
+#
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# --------------------------------------------------------------
+
+MKDIR=`which mkdir`
+UNZIP=`which unzip`
+ECHO=`which echo`
+FIND=`which find`
+GREP=`which grep`
+RM=`which rm`
+XARGS=`which xargs`
+SED=`which sed`
+CUT=`which cut`
+AWK=`which awk`
+IFCONFIG=`which ifconfig`
+HOSTNAME=`which hostname`
+SLEEP=`which sleep`
+TR=`which tr`
+HEAD=`which head`
+WGET=`which wget`
+PUPPETD=`which puppet`
+AGENT="agent"
+PUPPETAGENT="${PUPPETD} ${AGENT}"
+
+COMMAND="${PUPPETAGENT} -vt"
+IP=`${IFCONFIG} eth0 | ${GREP} -e "inet addr" | ${AWK} '{print $2}' | ${CUT} -d ':' -f 2`
+LOG=/tmp/puppet-init.log
+
+HOSTSFILE=/etc/hosts
+HOSTNAMEFILE=/etc/hostname
+PUPPETCONF=/etc/puppet/puppet.conf
+
+read_master() {
+ ${COMMAND}
+}
+
+is_public_ip_assigned() {
+
+while true
+do
+ wget http://169.254.169.254/latest/meta-data/public-ipv4
+ if [ ! -f public-ipv4 ]
+ then
+ echo "Public ipv4 file not found. Sleep and retry" >> $LOG
+ sleep 2;
+ continue;
+ else
+ echo "public-ipv4 file is available. Read value" >> $LOG
+ # Here means file is available. Read the file
+ read -r ip<public-ipv4;
+ echo "value is **[$ip]** " >> $LOG
+
+ if [ -z "$ip" ]
+ then
+ echo "File is empty. Retry...." >> $LOG
+ sleep 2
+ rm public-ipv4
+ continue
+ else
+ echo "public ip is assigned. value is [$ip]. Remove file" >> $LOG
+ rm public-ipv4
+ break
+ fi
+ fi
+done
+}
+
+DATE=`date +%d%m%y%S`
+RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
+
+if [ ! -d /tmp/payload ]; then
+
+ ## Check whether the public ip is assigned
+ is_public_ip_assigned
+
+ echo "Public ip have assigned. Continue.." >> $LOG
+
+ ## Clean old poop
+ ${ECHO} "Removing all existing certificates .."
+ #${FIND} /var/lib/puppet -type f -print0 | ${XARGS} -0r ${RM}
+
+ ${MKDIR} -p /tmp/payload
+ ${WGET} http://169.254.169.254/latest/user-data -O /tmp/payload/launch-params
+
+ cd /tmp/payload
+ SERVICE_NAME=`sed 's/,/\n/g' launch-params | grep SERVICE_NAME | cut -d "=" -f 2`
+ DEPLOYMENT=`sed 's/,/\n/g' launch-params | grep DEPLOYMENT | cut -d "=" -f 2`
+ INSTANCE_HOSTNAME=`sed 's/,/\n/g' launch-params | grep HOSTNAME | cut -d "=" -f 2`
+ PUPPET_IP=`sed 's/,/\n/g' launch-params | grep PUPPET_IP | cut -d "=" -f 2`
+ PUPPET_HOSTNAME=`sed 's/,/\n/g' launch-params | grep PUPPET_HOSTNAME | cut -d "=" -f 2`
+ PUPPET_ENV=`sed 's/,/\n/g' launch-params | grep PUPPET_ENV | cut -d "=" -f 2`
+ PUPPET_DNS_AVAILABLE=`sed 's/,/\n/g' launch-params | grep PUPPET_DNS_AVAILABLE | cut -d "=" -f 2`
+ NODEID="${RANDOMNUMBER}.${DEPLOYMENT}.${SERVICE_NAME}"
+
+
+
+ #essential to have PUPPET_HOSTNAME at the end in order to auto-sign the certs
+ DOMAIN="${PUPPET_HOSTNAME}"
+ ${ECHO} -e "\nNode Id ${NODEID}\n"
+ ${ECHO} -e "\nDomain ${DOMAIN}\n"
+ sed -i "s/server=.*/server=${PUPPET_HOSTNAME}/g" ${PUPPETCONF}
+ /etc/init.d/puppet restart
+ ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
+ HOST="${NODEID}.${DOMAIN}"
+ ${HOSTNAME} ${HOST}
+ ${ECHO} "${HOST}" > ${HOSTNAMEFILE}
+ if [ true != $PUPPET_DNS_AVAILABLE ] ; then
+ ${ECHO} "${PUPPET_IP} ${PUPPET_HOSTNAME}" >> ${HOSTSFILE}
+ fi
+
+ ${ECHO} "127.0.0.1 ${HOST}" >> ${HOSTSFILE}
+ echo ${HOST} > /proc/sys/kernel/hostname
+
+ PUPPET=`which puppet`
+ PUPPETAGENT="${PUPPET} agent"
+ RUNPUPPET="${PUPPETAGENT} -vt"
+
+ ${SLEEP} 5
+
+ ${PUPPETAGENT} --enable
+
+ ${RUNPUPPET} --server=${PUPPET_HOSTNAME}
+
+ ${PUPPETAGENT} --disable
+ ${ECHO} -e "Initialization completed successfully."
+
+fi
+
+# END
+
http://git-wip-us.apache.org/repos/asf/stratos/blob/6ff689f8/tools/init-scripts/openstack/ubuntu/init.sh
----------------------------------------------------------------------
diff --git a/tools/init-scripts/openstack/ubuntu/init.sh b/tools/init-scripts/openstack/ubuntu/init.sh
new file mode 100755
index 0000000..6841808
--- /dev/null
+++ b/tools/init-scripts/openstack/ubuntu/init.sh
@@ -0,0 +1,165 @@
+#!/bin/bash
+# --------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# --------------------------------------------------------------
+
+MKDIR=`which mkdir`
+UNZIP=`which unzip`
+ECHO=`which echo`
+FIND=`which find`
+GREP=`which grep`
+RM=`which rm`
+XARGS=`which xargs`
+SED=`which sed`
+CUT=`which cut`
+AWK=`which awk`
+IFCONFIG=`which ifconfig`
+HOSTNAME=`which hostname`
+SLEEP=`which sleep`
+TR=`which tr`
+HEAD=`which head`
+WGET=`which wget`
+PUPPETD=`which puppet`
+AGENT="agent"
+PUPPETAGENT="${PUPPETD} ${AGENT}"
+OS=$(lsb_release -si)
+PUPPET_DNS_AVAILABLE=false
+
+COMMAND="${PUPPETAGENT} -vt"
+IP=`${IFCONFIG} eth0 | ${GREP} -e "inet addr" | ${AWK} '{print $2}' | ${CUT} -d ':' -f 2`
+LOG=/tmp/puppet-init.log
+
+HOSTSFILE=/etc/hosts
+HOSTNAMEFILE=/etc/hostname
+PUPPETCONF=/etc/puppet/puppet.conf
+
+read_master() {
+ ${COMMAND}
+}
+
+
+is_public_ip_assigned() {
+
+while true
+do
+ wget http://169.254.169.254/latest/meta-data/public-ipv4
+ if [ ! -f public-ipv4 ]
+ then
+ echo "Public ipv4 file not found. Sleep and retry" >> $LOG
+ sleep 2;
+ continue;
+ else
+ echo "public-ipv4 file is available. Read value" >> $LOG
+ # Here means file is available. Read the file
+ read -r ip<public-ipv4;
+ echo "value is **[$ip]** " >> $LOG
+
+ if [ -z "$ip" ]
+ then
+ echo "File is empty. Retry...." >> $LOG
+ sleep 2
+ rm public-ipv4
+ continue
+ else
+ echo "public ip is assigned. value is [$ip]. Remove file" >> $LOG
+ rm public-ipv4
+ break
+ fi
+ fi
+done
+}
+
+
+DATE=`date +%d%m%y%S`
+RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
+
+if [ ! -d /tmp/payload ]; then
+
+ ## Check whether the public ip is assigned
+ is_public_ip_assigned
+
+ echo "Public ip have assigned. Continue.." >> $LOG
+
+ ## Clean old poop
+ ${ECHO} "Removing all existing certificates .."
+ #${FIND} /var/lib/puppet -type f -print0 | ${XARGS} -0r ${RM}
+
+ ${MKDIR} -p /tmp/payload
+ ${WGET} http://169.254.169.254/latest/user-data -O /tmp/payload/launch-params
+
+ cd /tmp/payload
+ SERVICE_NAME=`sed 's/,/\n/g' launch-params | grep SERVICE_NAME | cut -d "=" -f 2`
+ DEPLOYMENT=`sed 's/,/\n/g' launch-params | grep DEPLOYMENT | cut -d "=" -f 2`
+ INSTANCE_HOSTNAME=`sed 's/,/\n/g' launch-params | grep HOSTNAME | cut -d "=" -f 2`
+ PUPPET_IP=`sed 's/,/\n/g' launch-params | grep PUPPET_IP | cut -d "=" -f 2`
+ PUPPET_HOSTNAME=`sed 's/,/\n/g' launch-params | grep PUPPET_HOSTNAME | cut -d "=" -f 2`
+ PUPPET_ENV=`sed 's/,/\n/g' launch-params | grep PUPPET_ENV | cut -d "=" -f 2`
+ PUPPET_DNS_AVAILABLE=`sed 's/,/\n/g' launch-params | grep PUPPET_DNS_AVAILABLE | cut -d "=" -f 2`
+
+ #If this property is not set, then set it as false
+ if [ -z $PUPPET_DNS_AVAILABLE ];then
+ PUPPET_DNS_AVAILABLE=false
+ fi
+ NODEID="${RANDOMNUMBER}.${DEPLOYMENT}.${SERVICE_NAME}"
+ #essential to have PUPPET_HOSTNAME at the end in order to auto-sign the certs
+ DOMAIN="${PUPPET_HOSTNAME}"
+ ${ECHO} -e "\nNode Id ${NODEID}\n"
+ ${ECHO} -e "\nDomain ${DOMAIN}\n"
+ sed -i "s/server=.*/server=${PUPPET_HOSTNAME}/g" ${PUPPETCONF}
+ /etc/init.d/puppet restart
+ ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
+ HOST="${NODEID}.${DOMAIN}"
+ ${HOSTNAME} ${HOST}
+ ${ECHO} "${HOST}" > ${HOSTNAMEFILE}
+ if [ true != $PUPPET_DNS_AVAILABLE ] ; then
+ ${ECHO} "${PUPPET_IP} ${PUPPET_HOSTNAME}" >> ${HOSTSFILE}
+ fi
+ ${ECHO} "127.0.0.1 ${HOST}" >> ${HOSTSFILE}
+
+ if [ "$OS" = "CentOS" ]; then
+ #CentOS hostname change
+ ${ECHO} "CentOS : Changing host name in /etc/sysconfig/network"
+ CENTOSHOSTNAME="/etc/sysconfig/network"
+ ${ECHO} "NETWORKING=yes" > ${CENTOSHOSTNAME}
+ ${ECHO} "HOSTNAME=${HOST}" >> ${CENTOSHOSTNAME}
+ ${ECHO} "Network restarting..."
+ /etc/init.d/network restart
+ ${SLEEP} 4
+ else
+ #Ubuntu hostname change
+ /etc/init.d/hostname start
+ fi
+
+ PUPPET=`which puppet`
+ PUPPETAGENT="${PUPPET} agent"
+ RUNPUPPET="${PUPPETAGENT} -vt"
+
+ ${SLEEP} 5
+
+ ${PUPPETAGENT} --enable
+
+ ${RUNPUPPET}
+
+ ${PUPPETAGENT} --disable
+ ${ECHO} -e "Initialization completed successfully."
+
+fi
+
+# END
[5/7] stratos git commit: Removing python prefix
Posted by ud...@apache.org.
Removing python prefix
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/39821ee8
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/39821ee8
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/39821ee8
Branch: refs/heads/master
Commit: 39821ee848e60a8379228a10092c983e28bdc645
Parents: af66dee
Author: anuruddhal <an...@gmail.com>
Authored: Wed Jun 3 18:21:42 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Wed Jun 3 18:21:42 2015 +0530
----------------------------------------------------------------------
tools/config-scripts/ec2/config.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/39821ee8/tools/config-scripts/ec2/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/ec2/config.sh b/tools/config-scripts/ec2/config.sh
index 9c5bcef..880a778 100755
--- a/tools/config-scripts/ec2/config.sh
+++ b/tools/config-scripts/ec2/config.sh
@@ -33,7 +33,7 @@ CP=`which cp`
MV=`which mv`
HOSTSFILE=/etc/hosts
-LOCKFILE=/mnt/apache-stratos-python-cartridge-agent-4.1.0/wso2carbon.lck
+LOCKFILE=/mnt/apache-stratos-cartridge-agent-4.1.0/wso2carbon.lck
DATE=`date +%d%m%y%S`
RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
[3/7] stratos git commit: fix indentation
Posted by ud...@apache.org.
fix indentation
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/322dd17f
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/322dd17f
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/322dd17f
Branch: refs/heads/master
Commit: 322dd17f459182c0554e0220bc815a36c62add80
Parents: 794097a
Author: anuruddhal <an...@gmail.com>
Authored: Wed Jun 3 18:03:21 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Wed Jun 3 18:03:21 2015 +0530
----------------------------------------------------------------------
.../src/main/python/cartridge.agent/cartridge.agent/agent.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/322dd17f/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/agent.py
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/agent.py b/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/agent.py
index 39010db..0da1b18 100644
--- a/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/agent.py
+++ b/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/agent.py
@@ -128,7 +128,7 @@ class CartridgeAgent(threading.Thread):
:return: void
"""
self.__terminated = True
-
+
def register_instance_topic_listeners(self):
self.__log.debug("Starting instance notifier event message receiver thread")
[7/7] stratos git commit: Fixing merge conflicts
Posted by ud...@apache.org.
Fixing merge conflicts
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/175a57a7
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/175a57a7
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/175a57a7
Branch: refs/heads/master
Commit: 175a57a7d70f51a1c5d74502090e8dba3b42fdfe
Parents: df472e0
Author: anuruddhal <an...@gmail.com>
Authored: Thu Jun 4 14:42:10 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Thu Jun 4 14:42:10 2015 +0530
----------------------------------------------------------------------
tools/config-scripts/gce/config.sh | 4 ----
tools/config-scripts/openstack/config.sh | 2 +-
2 files changed, 1 insertion(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/175a57a7/tools/config-scripts/gce/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/gce/config.sh b/tools/config-scripts/gce/config.sh
index a8daa10..ab75b12 100644
--- a/tools/config-scripts/gce/config.sh
+++ b/tools/config-scripts/gce/config.sh
@@ -91,14 +91,10 @@ if [[ $answer = y ]] ; then
ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
${ECHO} "\nRunning puppet installation with arguments: ${ARGS[@]}"
/root/bin/puppetinstall/puppetinstall "${ARGS[@]}"
-<<<<<<< HEAD
- ${RM} /mnt/apache-stratos-cartridge-agent-4.1.0/wso2carbon.lck
-=======
if [ -e ${LOCKFILE} ]; then
${RM} ${LOCKFILE}
fi
->>>>>>> upstream/master
${GREP} -q '/root/bin/init.sh > /tmp/puppet_log' /etc/rc.local || ${SED} -i 's/exit 0$/\/root\/bin\/init.sh \> \/tmp\/puppet_log\nexit 0/' /etc/rc.local
${RM} -rf /tmp/*
${RM} -rf /var/lib/puppet/ssl/*
http://git-wip-us.apache.org/repos/asf/stratos/blob/175a57a7/tools/config-scripts/openstack/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/openstack/config.sh b/tools/config-scripts/openstack/config.sh
index 880a778..76f04dc 100755
--- a/tools/config-scripts/openstack/config.sh
+++ b/tools/config-scripts/openstack/config.sh
@@ -91,7 +91,7 @@ if [[ $answer = y ]] ; then
/root/bin/puppetinstall/puppetinstall "${ARGS[@]}"
#check for java agent lock file
if [ -e ${LOCKFILE} ]; then
- ${RM} ${LOCKFILE}
+ ${RM} ${LOCKFILE}
fi
${GREP} -q '/root/bin/init.sh > /tmp/puppet_log' /etc/rc.local || ${SED} -i 's/exit 0$/\/root\/bin\/init.sh \> \/tmp\/puppet_log\nexit 0/' /etc/rc.local
[2/7] stratos git commit: Fixing python agent unzip error
Posted by ud...@apache.org.
Fixing python agent unzip error
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/794097a7
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/794097a7
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/794097a7
Branch: refs/heads/master
Commit: 794097a7afcf58115f75c787cc9e398126c064f9
Parents: 6ff689f
Author: anuruddhal <an...@gmail.com>
Authored: Wed Jun 3 18:00:58 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Wed Jun 3 18:00:58 2015 +0530
----------------------------------------------------------------------
tools/puppet3/modules/python_agent/manifests/initialize.pp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/794097a7/tools/puppet3/modules/python_agent/manifests/initialize.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/modules/python_agent/manifests/initialize.pp b/tools/puppet3/modules/python_agent/manifests/initialize.pp
index 452a9ac..9013fe6 100755
--- a/tools/puppet3/modules/python_agent/manifests/initialize.pp
+++ b/tools/puppet3/modules/python_agent/manifests/initialize.pp
@@ -81,7 +81,7 @@ define python_agent::initialize ($repo, $version, $agent_name, $local_dir, $targ
exec {
"extracting_${agent_name}.zip_for_${name}":
path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
- cwd => "$target/${agent_name}",
+ cwd => "$target",
unless => "test -d ${target}/${agent_name}/agent.conf",
command => "unzip -o ${local_dir}/${agent_name}.zip",
logoutput => 'on_failure',
[4/7] stratos git commit: Changing the agent version to 4.1.0
Posted by ud...@apache.org.
Changing the agent version to 4.1.0
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/af66dee4
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/af66dee4
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/af66dee4
Branch: refs/heads/master
Commit: af66dee47a4171ac3f2bf0f73935534752d3da8b
Parents: 322dd17
Author: anuruddhal <an...@gmail.com>
Authored: Wed Jun 3 18:19:51 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Wed Jun 3 18:19:51 2015 +0530
----------------------------------------------------------------------
tools/config-scripts/ec2/config.sh | 2 +-
tools/config-scripts/gce/config.sh | 2 +-
tools/config-scripts/openstack/config.sh | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/af66dee4/tools/config-scripts/ec2/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/ec2/config.sh b/tools/config-scripts/ec2/config.sh
index 4ac4707..9c5bcef 100755
--- a/tools/config-scripts/ec2/config.sh
+++ b/tools/config-scripts/ec2/config.sh
@@ -33,7 +33,7 @@ CP=`which cp`
MV=`which mv`
HOSTSFILE=/etc/hosts
-LOCKFILE=/mnt/apache-stratos-cartridge-agent-4.0.0/wso2carbon.lck
+LOCKFILE=/mnt/apache-stratos-python-cartridge-agent-4.1.0/wso2carbon.lck
DATE=`date +%d%m%y%S`
RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
http://git-wip-us.apache.org/repos/asf/stratos/blob/af66dee4/tools/config-scripts/gce/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/gce/config.sh b/tools/config-scripts/gce/config.sh
index 0c1cbc7..6f03e4e 100644
--- a/tools/config-scripts/gce/config.sh
+++ b/tools/config-scripts/gce/config.sh
@@ -90,7 +90,7 @@ if [[ $answer = y ]] ; then
ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
${ECHO} "\nRunning puppet installation with arguments: ${ARGS[@]}"
/root/bin/puppetinstall/puppetinstall "${ARGS[@]}"
- ${RM} /mnt/apache-stratos-cartridge-agent-4.0.0/wso2carbon.lck
+ ${RM} /mnt/apache-stratos-cartridge-agent-4.1.0/wso2carbon.lck
${GREP} -q '/root/bin/init.sh > /tmp/puppet_log' /etc/rc.local || ${SED} -i 's/exit 0$/\/root\/bin\/init.sh \> \/tmp\/puppet_log\nexit 0/' /etc/rc.local
${RM} -rf /tmp/*
${RM} -rf /var/lib/puppet/ssl/*
http://git-wip-us.apache.org/repos/asf/stratos/blob/af66dee4/tools/config-scripts/openstack/config.sh
----------------------------------------------------------------------
diff --git a/tools/config-scripts/openstack/config.sh b/tools/config-scripts/openstack/config.sh
index 4ac4707..880a778 100755
--- a/tools/config-scripts/openstack/config.sh
+++ b/tools/config-scripts/openstack/config.sh
@@ -33,7 +33,7 @@ CP=`which cp`
MV=`which mv`
HOSTSFILE=/etc/hosts
-LOCKFILE=/mnt/apache-stratos-cartridge-agent-4.0.0/wso2carbon.lck
+LOCKFILE=/mnt/apache-stratos-cartridge-agent-4.1.0/wso2carbon.lck
DATE=`date +%d%m%y%S`
RANDOMNUMBER="`${TR} -c -d 0-9 < /dev/urandom | ${HEAD} -c 4`${DATE}"
[6/7] stratos git commit: Fixing merge conflicts
Posted by ud...@apache.org.
Fixing merge conflicts
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/df472e0c
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/df472e0c
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/df472e0c
Branch: refs/heads/master
Commit: df472e0cf71d9a70ef62167b16e1ba3f62a59d6e
Parents: 39821ee c14c6b1
Author: anuruddhal <an...@gmail.com>
Authored: Thu Jun 4 14:39:12 2015 +0530
Committer: anuruddhal <an...@gmail.com>
Committed: Thu Jun 4 14:39:12 2015 +0530
----------------------------------------------------------------------
.../stratos/cloud/controller/iaases/gce/GCEIaas.java | 4 ++--
.../stratos/common/constants/StratosConstants.java | 1 +
.../LoadBalancerCommonTopologyEventReceiver.java | 13 +++++++++----
.../load/balancer/conf/LoadBalancerConfiguration.java | 9 ++++++---
.../conf/configurator/TopologyFilterConfigurator.java | 6 ++++++
.../resources/sample/configuration/loadbalancer3.conf | 2 +-
.../distribution/src/main/conf/loadbalancer.conf | 1 -
tools/config-scripts/gce/config.sh | 8 ++++++++
8 files changed, 33 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/df472e0c/tools/config-scripts/gce/config.sh
----------------------------------------------------------------------
diff --cc tools/config-scripts/gce/config.sh
index 6f03e4e,ab75b12..a8daa10
--- a/tools/config-scripts/gce/config.sh
+++ b/tools/config-scripts/gce/config.sh
@@@ -90,7 -91,10 +91,14 @@@ if [[ $answer = y ]] ; the
ARGS=("-n${NODEID}" "-d${DOMAIN}" "-s${PUPPET_IP}")
${ECHO} "\nRunning puppet installation with arguments: ${ARGS[@]}"
/root/bin/puppetinstall/puppetinstall "${ARGS[@]}"
++<<<<<<< HEAD
+ ${RM} /mnt/apache-stratos-cartridge-agent-4.1.0/wso2carbon.lck
++=======
+ if [ -e ${LOCKFILE} ]; then
+ ${RM} ${LOCKFILE}
+ fi
+
++>>>>>>> upstream/master
${GREP} -q '/root/bin/init.sh > /tmp/puppet_log' /etc/rc.local || ${SED} -i 's/exit 0$/\/root\/bin\/init.sh \> \/tmp\/puppet_log\nexit 0/' /etc/rc.local
${RM} -rf /tmp/*
${RM} -rf /var/lib/puppet/ssl/*