All Downloads are FREE. Search and download functionalities are using the official Maven repository.

res.ant.jasmine_installation.xml Maven / Gradle / Ivy

<?xml version="1.0" encoding="UTF-8" ?>
<!--
  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  - JASMINe
  - Copyright (C) 2009 Bull S.A.S.
  - Contact: [email protected]
  -
  - This library is free software; you can redistribute it and/or
  - modify it under the terms of the GNU Lesser General Public
  - License as published by the Free Software Foundation; either
  - version 2.1 of the License, or any later version.
  -
  - This library is distributed in the hope that it will be useful,
  - but WITHOUT ANY WARRANTY; without even the implied warranty of
  - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  - Lesser General Public License for more details.
  -
  - You should have received a copy of the GNU Lesser General Public
  - License along with this library; if not, write to the Free Software
  - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
  - USA
  -
  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  - $Id$
  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-->
<project name="JASMINe_installation_scripts" xmlns:jant="http://jonas.objectweb.org/ant">

	<typedef resource="org/ow2/jonas/ant/antlib.xml" classpath="jonas-ant-tasks.jar" uri="http://jonas.objectweb.org/ant" />

	<!--
	  Define conditions
	-->
	<condition property="smtp_need_authentication">
		<istrue value="${smtp.need.authentication}" />
	</condition>

	<condition property="use_default_db">
		<istrue value="${database.use_default}" />
	</condition>

	<condition property="user_agree">
		<istrue value="${user_agree}" />
	</condition>

	<!--
	  Send product informations
	-->
	<target name="send_product_informations" if="user_agree">
		<java jar="${INSTALL_PATH}/installer/geoclient.jar" fork="true">
			<!--<arg line="JASMINe-Monitoring 1.2.1-M8 &quot;${user.email.address}&quot; ${installer.proxyaddress} ${installer.proxyport} ${installer.proxyuser} ${installer.proxypwd}" />-->
			<arg value="JASMINe-Monitoring" />
			<arg value="1.2.1-M8" />
		    <arg value="${user.email.address}" />
			<arg value="${installer.proxyaddress}" />
			<arg value="${installer.proxyport}" />
			<arg value="${installer.proxyuser}" />
			<arg value="${installer.proxypwd}" />
		</java>
	</target>

	<!--
	  Configuration for JASMINe Monitoring - core
	-->

	<!-- Create a new JOnAS Base -->
	<target name="create_jonas_base_for_jasmine">
		<jant:jonasbase jonasRoot="${jonas.root}" destDir="${jonas.base}" update="off">
			<jonasProperties services="jtm,db,security,resource,mail,ejb3,web,ear,depmonitor" master="false" development="false" />
			<carol defaultPort="${rmi.port}" protocols="jrmp" jrmpOptimization="true" localRegistry="true" />
			<jms port="${jms.port}" initialTopics="jasmine,jasmineNotification" />
			<webcontainer name="tomcat">
			    <tomcat>
			    	<http port="${http.port}" />
			    </tomcat>
			</webcontainer>
			<mail type="Session" name="JASMINeMailSession" />
			<jdbcRa name="db_access_jdbc1" mapperName="rdb.hsql" user="jonas" password="jonas" url="jdbc:hsqldb:hsql://localhost:9001/db_jonas" driverName="org.hsqldb.jdbcDriver" maxPoolSize="100" jndiName="jdbc_1" autoload="on" p6spy="off" />
		</jant:jonasbase>

		<copy file="${jonas.base}/repositories/url-internal/zz_jasmine-monitoring.xml" todir="${jonas.base}/deploy" />
	</target>

	<target name="clean_deploy_directory">
		<move todir="${jonas.base}/deploy/available">
			<fileset dir="${jonas.base}/deploy">
				<include name="jonasAdmin.xml" />
				<include name="doc.xml" />
				<include name="mejb.xml" />
			</fileset>
		</move>
	</target>

	<!-- Configure eventswitch -->
	<target name="configure_eventswitch">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" token="1099" value="${rmi.port}" />
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" token="__INSTALL_PATH__" value="${INSTALL_PATH}" />
	</target>

	<!--  Change execution access on JOnAS scripts  -->
	<target name="grants_jonas">
		<chmod perm="755">
			<fileset dir="${jonas.root}/bin">
				<include name="**" />
			</fileset>
		</chmod>
	</target>

	<!--
	  Configuration for EoS (Eye of SOA)    
	-->

	<!-- configure eventswitch for EoS -->
	<target name="configure_eventswitch_eos">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[<!-- eos]]></replacetoken>
		</replace>
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[eos -->]]></replacetoken>
		</replace>
	</target>

	<!-- add and configure the service web (tomcat) -->
	<!--<target name="configure_service_web">
		<jant:jonasbase jonasRoot="${jonas.root}" destDir="${jonas.base}" update="on">
			<jonasProperties services="jtm,security,resource,ejb3,web,ear,depmonitor" />
			<webcontainer name="tomcat">
				<tomcat>
					<http port="${http.port}" />
				</tomcat>
			</webcontainer>
		</jant:jonasbase>
	</target>-->

	<!--  configure JAAS  -->
	<target name="configure_jaas">
		<concat destfile="${jonas.base}/conf/jaas.config" append="true"><![CDATA[eos {
  org.ow2.jonas.security.auth.spi.JResourceLoginModule required
  resourceName="memrlm_1"
  ;
};]]></concat>
	</target>


	<!--
      Configure MBeanCmd
    -->
	<target name="configure_eventswitch_mbeancmd">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" token="18564" value="${mbeancmd.port}" />
	</target>

	<!--
	    Configure DataBase
	  -->
	<!--<target name="configure_database" depends="configure_embedded_db, configure_external_db" />-->

	<!--<target name="configure_embedded_db">
		<jant:jonasbase jonasRoot="${jonas.root}" destDir="${jonas.base}" update="off">
			<jonasProperties services="jtm,db,security,resource,ejb3,web,ear,depmonitor" />
			<jdbcRa name="db_access_jdbc1" mapperName="rdb.hsql" user="jonas" password="jonas" url="jdbc:hsqldb:hsql://localhost:9001/db_jonas" driverName="org.hsqldb.jdbcDriver" maxPoolSize="100" jndiName="jdbc_1" autoload="on" p6spy="off" />
		</jant:jonasbase>
	</target>-->

	<!--<target name="configure_external_db" unless="use_default_db">
		<jant:jonasbase jonasRoot="${jonas.root}" destDir="${jonas.base}" update="off">
			<jdbcRa name="db_access_jdbc1" user="${database.username}" password="${database.password}" url="${database.url}" jndiName="jdbc_1" autoload="on" p6spy="off" />
		</jant:jonasbase>
	</target>-->

	<!-- configure eventswitch for  Database -->
	<target name="configure_eventswitch_database">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[<!-- database]]></replacetoken>
		</replace>
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[database -->]]></replacetoken>
		</replace>
	</target>

	<!--
	  Configure notification system
	-->
	<target name="configure_eventswitch_notif">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[<!-- drools]]></replacetoken>
		</replace>
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[drools -->]]></replacetoken>
		</replace>
	</target>

	<!--
	  Configure Log
	-->
	<target name="configure_log">
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[<!-- log]]></replacetoken>
		</replace>
		<replace file="${INSTALL_PATH}/conf/eventswitch-config.xml" value="">
			<replacetoken><![CDATA[log -->]]></replacetoken>
		</replace>
	</target>

	<!--
	  Configure e-mail service
    -->
	<target name="configure_mail">
		<!--<jant:jonasbase jonasRoot="${jonas.root}" destDir="${jonas.base}" update="off">
			<jonasProperties services="jtm,db,security,resource,mail,ejb3,web,ear,depmonitor" master="false" development="false" />
			<mail type="Session" name="mailSession1" />
		</jant:jonasbase>-->

		<concat destfile="${jonas.base}/conf/JASMINeMailSession.properties" append="true">mail.smtp.host ${smtp.server}</concat>
		<concat destfile="${jonas.base}/conf/JASMINeMailSession.properties" append="true">mail.smtp.port ${smtp.port}</concat>
	</target>

	<target name="configure_secure_mail" if="smtp_need_authentication">
		<concat destfile="${jonas.base}/conf/JASMINeMailSession.properties" append="true">mail.authentication.username ${smtp.username}</concat>
		<concat destfile="${jonas.base}/conf/JASMINeMailSession.properties" append="true">mail.authentication.password ${smtp.password}</concat>
	</target>

</project>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy