Properly replace paths in configuration templates with URLs
authorwassa <wassa@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Fri, 27 May 2005 22:33:24 +0000 (22:33 +0000)
committerwassa <wassa@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Fri, 27 May 2005 22:33:24 +0000 (22:33 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/trunk@1585 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

build.xml

index 42239cd..274a51c 100755 (executable)
--- a/build.xml
+++ b/build.xml
     <target name="install.init">
         <taskdef name="xinput" classname="edu.internet2.middleware.shibboleth.utils.ant.XInput" classpath="${build}" />
         <typedef name="xoption" classname="edu.internet2.middleware.shibboleth.utils.ant.XInputOption" classpath="${build}" />
+               <taskdef name="urlconvert" classname="edu.internet2.middleware.shibboleth.utils.ant.URLConvert" classpath="${build}"/>
     </target>
 
     <target name="install" depends="init, install.init" description="Install Shibboleth">
         <input message="Select an installation base for the Shibboleth Identity Provider [default: ${shib.home}]"
             addproperty="shib.home.input" defaultvalue="${shib.home}" />
         <var name="shib.home" value="${shib.home.input}" />
-
+               <urlconvert path="${shib.home}" addProperty="shib.home.url"/>
         <input message="Enter tomcat home directory [default: ${tomcat.home}]"
             addproperty="tomcat.home.input" defaultvalue="${tomcat.home}" />
         <var name="tomcat.home" value="${tomcat.home.input}" />
 
         <!-- copy values to deployment descriptor and create war -->
         <copy file="${configroot}/dist.idp.xml" tofile="${configroot}/idp.xml" overwrite="true" />
-        <replace file="${configroot}/idp.xml" token="$SHIB_HOME$" value="${shib.home}" />
+        <replace file="${configroot}/idp.xml" token="$SHIB_HOME$" value="${shib.home.url}" />
         <war warfile="${dist}/${shib.webapp.name}.war" webxml="${configroot}/idp.xml" basedir="${approot}" update="no" />
                <delete file="${configroot}/idp.xml"/>
         <copy file="${dist}/${shib.webapp.name}.war" tofile="${tomcat.home}/webapps/${shib.webapp.name}.war" />
             <fileset dir="${src}/conf" includesfile="conf/idp-conf.include"/>
         </copy>
                <move file="${shib.home}/etc/dist.idp.xml" tofile="${shib.home}/etc/idp.xml" overwrite="true" />
-        <replace file="${shib.home}/etc/idp.xml" token="$SHIB_HOME$" value="${shib.home}" />
+        <replace file="${shib.home}/etc/idp.xml" token="$SHIB_HOME$" value="${shib.home.url}" />
     </target>
 
     <!-- install Shibboleth-IdP war using tomcat's manager app -->