Skip to content

Instantly share code, notes, and snippets.

@imesh
imesh / copy_activemq_libs.sh
Last active Aug 29, 2015
Copy ActiveMQ libraries required for Stratos 4.0.0 to a target path
View copy_activemq_libs.sh
activemq_version=5.8.0
activemq_home=/home/ubuntu/packages/apache-activemq-5.8.0
copy_libs() {
target_lib_path=$1
cp ${activemq_home}/lib/activemq-broker-${activemq_version}.jar ${target_lib_path}
cp ${activemq_home}/lib/activemq-client-${activemq_version}.jar ${target_lib_path}
cp ${activemq_home}/lib/geronimo-j2ee-management_1.1_spec-1.0.1.jar ${target_lib_path}
cp ${activemq_home}/lib/geronimo-jms_1.1_spec-1.1.1.jar ${target_lib_path}
cp ${activemq_home}/lib/hawtbuf-1.9.jar ${target_lib_path}
View copy-stratos-packs.sh
#!/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
#
@imesh
imesh / scp_stratos_packs.sh
Last active Aug 29, 2015
SCP Stratos Packs to a server
View scp_stratos_packs.sh
# NOT COMPLETED
stratos_version=4.0.0-incubating
cep_extension_name=apache-stratos-cep-extension-${stratos_version}
cep_extension_path=/tmp/${cep_extension_name}
echo "Creating CEP extension pack..."
if [[ ! -d ${cep_extension_path} ]]; then
mkdir ${cep_extension_path}
fi
@imesh
imesh / sign-stratos-packs.sh
Last active Aug 29, 2015
Sign stratos packages
View sign-stratos-packs.sh
#!/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
#
@imesh
imesh / release-stratos.sh
Last active Aug 29, 2015
Deploy maven artifacts to Apache snapshots and staging repositories.
View release-stratos.sh
#!/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
#
@imesh
imesh / pedantic-verify.sh
Created Apr 26, 2014
Run Apache Rat tool and verify licenses
View pedantic-verify.sh
mvn -P pedantic verify -DskipTests=true
@imesh
imesh / copy_stratos_packs_from_dist.sh
Created Apr 26, 2014
Copy Stratos packs from dist to packages folder and puppet master
View copy_stratos_packs_from_dist.sh
set -e
source_path="/mnt/dist/4.0.0-incubating-rc1"
stratos_version=4.0.0-incubating
dist_path="/home/ubuntu/packages"
puppet_master_path=/etc/puppet
stratos_pack=apache-stratos-$stratos_version.zip
stratos_path=$source_path/$stratos_pack
lb_pack=apache-stratos-load-balancer-$stratos_version.zip
lb_path=$source_path/$lb_pack
@imesh
imesh / verify-stratos-release.sh
Created May 5, 2014
Verify signatures and hash values of a Stratos release
View verify-stratos-release.sh
#!/bin/sh
md5=".md5"
sha1=".sha1"
asc=".asc"
for f0 in *.zip
do
echo $f0
f2=$f0$md5
@imesh
imesh / listAllUsersInSeq.xml
Created May 15, 2014
List all users in sequence.
View listAllUsersInSeq.xml
<sequence xmlns="http://ws.apache.org/ns/synapse" name="ListUsersInSeq">
<payloadFactory media-type="xml">
<format>
<xsd:listAllUsers xmlns:xsd="http://org.apache.axis2/xsd">
<xsd:filter>$1</xsd:filter>
<xsd:limit>$2</xsd:limit>
</xsd:listAllUsers>
</format>
<args>
<arg xmlns:m0="http://services.samples" evaluator="xml" expression="$url:filter"/>
View list-all-users-out-sequence.xml
<sequence xmlns="http://ws.apache.org/ns/synapse" name="ListUsersOutSeq">
<log level="full"/>
<property name="messageType" value="application/json" scope="axis2" type="STRING"/>
<send/>
</sequence>