blob: a897225b6b87c788b9f71a42a0408d486fcfff43 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<project name="build-packaging" xmlns:ivy="antlib:org.apache.ivy.ant">
<path id="bundles">
</path>
<property file="${basedir}/../build.properties"/>
<property file="${basedir}/../build.versions"/>
<import file="${basedir}/../virgo-build/multi-bundle/default.xml"/>
<import file="${basedir}/nano/build-nano.xml"/>
<import file="${basedir}/kernel/build-kernel.xml"/>
<import file="${basedir}/tomcat-server/build-tomcat-server.xml"/>
<import file="${basedir}/jetty-server/build-jetty-server.xml"/>
<property name="nano.target.dir" value="${target.dir}/nano"/>
<property name="kernel.target.dir" value="${target.dir}/kernel"/>
<property name="tomcat-server.target.dir" value="${target.dir}/tomcat-server"/>
<property name="jetty-server.target.dir" value="${target.dir}/jetty-server"/>
<target name="package" depends="ivy.init,fetch-unzipped-virgo-build-tools">
<delete dir="${package.output.dir}" quiet="true"/>
<mkdir dir="${package.output.dir}"/>
<antcall target="package-nano"/>
<antcall target="package-kernel"/>
<antcall target="package-tomcat-server"/>
<antcall target="package-jetty-server"/>
<delete dir="${tools.dir}" quiet="true"/>
</target>
<target name="smoke-test">
<antcall target="smoke-test-nano"/>
<antcall target="smoke-test-kernel"/>
<antcall target="smoke-test-tomcat-server"/>
<antcall target="smoke-test-jetty-server"/>
</target>
<property name="nano.package.file" value="${artifacts.dir}/virgo-nano-${bundle.version}.zip"/>
<property name="nano.full.package.file" value="${artifacts.dir}/virgo-nano-full-${bundle.version}.zip"/>
<property name="kernel.package.file" value="${artifacts.dir}/virgo-kernel-${bundle.version}.zip"/>
<property name="tomcat-server.package.file" value="${artifacts.dir}/virgo-tomcat-server-${bundle.version}.zip"/>
<property name="jetty-server.package.file" value="${artifacts.dir}/virgo-jetty-server-${bundle.version}.zip"/>
<target name="publish-packages-build">
<antcall target="publish-package-build-temp">
<param name="package.file" value="${nano.package.file}"/>
</antcall>
<antcall target="publish-package-build-temp">
<param name="package.file" value="${nano.full.package.file}"/>
</antcall>
<antcall target="publish-package-build-temp">
<param name="package.file" value="${kernel.package.file}"/>
</antcall>
<antcall target="publish-package-build-temp">
<param name="package.file" value="${tomcat-server.package.file}"/>
</antcall>
<antcall target="publish-package-build-temp">
<param name="package.file" value="${jetty-server.package.file}"/>
</antcall>
</target>
<target name="publish-packages-download">
<antcall target="publish-package-download-temp">
<param name="package.file" value="${nano.package.file}"/>
</antcall>
<antcall target="publish-package-download-temp">
<param name="package.file" value="${nano.full.package.file}"/>
</antcall>
<antcall target="publish-package-download-temp">
<param name="package.file" value="${kernel.package.file}"/>
</antcall>
<antcall target="publish-package-download-temp">
<param name="package.file" value="${tomcat-server.package.file}"/>
</antcall>
<antcall target="publish-package-download-temp">
<param name="package.file" value="${jetty-server.package.file}"/>
</antcall>
</target>
<!-- TODO:this might be better off in virgo-build -->
<target name="publish-package-build-temp">
<fail message="The 'package.file' property must be set on this project.">
<condition>
<not>
<isset property="package.file"/>
</not>
</condition>
</fail>
<fail message="The 'project.name' property must be set on this project.">
<condition>
<not>
<isset property="project.name"/>
</not>
</condition>
</fail>
<checksum file="${package.file}" algorithm="sha1"/>
<sshexec host="build.eclipse.org"
username="${eclipse.buildId}"
keyfile="${key.file}"
passphrase="${passphrase}"
command="mkdir -pv /opt/public/rt/virgo/zips/${adjusted.release.type}/${project.key}/${bundle.version}"/>
<scp localFile="${package.file}"
todir="${eclipse.buildId}@build.eclipse.org:/opt/public/rt/virgo/zips/${adjusted.release.type}/${project.key}/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
<scp localFile="${package.file}.sha1"
todir="${eclipse.buildId}@build.eclipse.org:/opt/public/rt/virgo/zips/${adjusted.release.type}/${project.key}/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
</target>
<!-- TODO:this might be better off in virgo-build -->
<target name="publish-package-download-temp">
<fail message="The 'package.file' property must be set on this project.">
<condition>
<not>
<isset property="package.file"/>
</not>
</condition>
</fail>
<fail message="The 'project.name' property must be set on this project.">
<condition>
<not>
<isset property="project.name"/>
</not>
</condition>
</fail>
<checksum file="${package.file}" algorithm="sha1"/>
<sshexec host="build.eclipse.org"
username="${eclipse.committerId}"
keyfile="${key.file}"
passphrase="${passphrase}"
command="mkdir -pv /home/data/httpd/download.eclipse.org/virgo/${adjusted.release.type}/${project.key}/${bundle.version}"/>
<scp localFile="${package.file}"
todir="${eclipse.committerId}@build.eclipse.org:/home/data/httpd/download.eclipse.org/virgo/${adjusted.release.type}/${project.key}/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
<scp localFile="${package.file}.sha1"
todir="${eclipse.committerId}@build.eclipse.org:/home/data/httpd/download.eclipse.org/virgo/${adjusted.release.type}/${project.key}/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
</target>
<target name="publish-updatesite-download">
<fail message="The 'project.name' property must be set on this project.">
<condition>
<not>
<isset property="project.name"/>
</not>
</condition>
</fail>
<checksum file="${updatesite.output.file}" algorithm="sha1"/>
<sshexec host="build.eclipse.org"
username="${eclipse.committerId}"
keyfile="${key.file}"
passphrase="${passphrase}"
command="mkdir -pv /home/data/httpd/download.eclipse.org/virgo/updatesite-zipped/${bundle.version}"/>
<sshexec host="build.eclipse.org"
username="${eclipse.committerId}"
keyfile="${key.file}"
passphrase="${passphrase}"
command="mkdir -pv /home/data/httpd/download.eclipse.org/virgo/updatesite/${bundle.version}"/>
<scp localFile="${updatesite.output.file}"
todir="${eclipse.committerId}@build.eclipse.org:/home/data/httpd/download.eclipse.org/virgo/updatesite-zipped/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
<scp localFile="${updatesite.output.file}.sha1"
todir="${eclipse.committerId}@build.eclipse.org:/home/data/httpd/download.eclipse.org/virgo/updatesite-zipped/${bundle.version}"
keyfile="${key.file}"
passphrase="${passphrase}" />
<sshexec host="build.eclipse.org"
username="${eclipse.committerId}"
keyfile="${key.file}"
passphrase="${passphrase}"
command="unzip /home/data/httpd/download.eclipse.org/virgo/updatesite-zipped/${bundle.version}/${updatesite.file.name} -d /home/data/httpd/download.eclipse.org/virgo/updatesite/${bundle.version}"/>
</target>
</project>