build.p5build_SE.SYSTEM.xml 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project basedir="../../schema" name="build_SE.SYSTEM"
  3. xmlns:p5build_SE="http://biuro.biall-net.pl/build_SE.xsd"
  4. >
  5. <include optional="true" file="build.p5build_SE.PRODUCT.xml"/>
  6. <include file="build.p5build_SE.SERVER.xml"/>
  7. <property name="build_SE.SYSTEM.build" location="${p5build_SE.basedir}/build.p5build_SE.SYSTEM.xml"/>
  8. <property name="p5build_SE.SYSTEM.config_dir" value="${basedir}/config"/>
  9. <include file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-user.xml" optional="true"/>
  10. <include file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-root.xml" optional="true"/>
  11. <property name="p5build_SE.SYSTEM.StandardOutPath" value="${p5build_SE.temp}/StandardOutPath"/>
  12. <property name="p5build_SE.SYSTEM.StandardErrorPath" value="${p5build_SE.temp}/StandardErrorPath"/>
  13. <condition property="p5build_SE.SYSTEM.StandardOutPath.notcreated" taskname="p5build_SE.SYSTEM.StandardOutPath">
  14. <not><available file="${p5build_SE.SYSTEM.StandardOutPath}"></available></not>
  15. </condition>
  16. <condition property="p5build_SE.SYSTEM.StandardErrorPath.notcreated" taskname="p5build_SE.SYSTEM.StandardErrorPath">
  17. <not><available file="${p5build_SE.SYSTEM.StandardErrorPath}"></available></not>
  18. </condition>
  19. <condition property="p5build_SE.SYSTEM.local-user.undef" taskname="p5build_SE.SYSTEM.local-user">
  20. <not><isset property="p5build_SE.SYSTEM.local-user"/></not>
  21. </condition>
  22. <condition property="p5build_SE.SYSTEM.local-root.undef" taskname="p5build_SE.SYSTEM.local-root">
  23. <not><isset property="p5build_SE.SYSTEM.local-root"/></not>
  24. </condition>
  25. <!-- <property name="p5build_SE.SYSTEM.local-user" value="a.binder"/><!-\- type local username for files creations permitions - some root tasks should chown it to this UID to allow for him to read -\->
  26. <property name="p5build_SE.SYSTEM.local-root" value="root"/> <!-\- name of system user account to make some root tasks -\->-->
  27. <target name="build_SE.SYSTEM" depends="p5build_SE.SYSTEM.local-user,p5build_SE.SYSTEM.local-root,p5build_SE.SYSTEM.StandardOutPath,p5build_SE.SYSTEM.StandardErrorPath"/>
  28. <target name="p5build_SE.SYSTEM.local-user" if="p5build_SE.SYSTEM.local-user.undef">
  29. <input addproperty="p5build_SE.SYSTEM.local-user" message=" type local username for files creations permitions - some root tasks should chown it to this UID to allow for him to read"/>
  30. <mkdir dir="${p5build_SE.SYSTEM.config_dir}"/>
  31. <echoxml file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-user.xml">
  32. <project basedir="${basedir}" name="build_SE.SYSTEM.local-user"
  33. xmlns:p5build_SE="http://biuro.biall-net.pl/build_SE.xsd"
  34. >
  35. <property name="p5build_SE.SYSTEM.local-user" value="${p5build_SE.SYSTEM.local-user}"/><!-- type local username for files creations permitions - some root tasks should chown it to this UID to allow for him to read -->
  36. </project>
  37. </echoxml>
  38. <chown file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-user.xml" owner="${p5build_SE.SYSTEM.local-user}" failonerror="false"/>
  39. </target>
  40. <target name="p5build_SE.SYSTEM.local-root" if="p5build_SE.SYSTEM.local-root.undef">
  41. <input addproperty="p5build_SE.SYSTEM.local-root" message=" name of system user account to make some root tasks"/>
  42. <mkdir dir="${p5build_SE.SYSTEM.config_dir}"/>
  43. <echoxml file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-root.xml">
  44. <project basedir="${basedir}" name="build_SE.SYSTEM.local-root"
  45. xmlns:p5build_SE="http://biuro.biall-net.pl/build_SE.xsd"
  46. >
  47. <property name="p5build_SE.SYSTEM.local-root" value="${p5build_SE.SYSTEM.local-root}"/><!-- type local username for files creations permitions - some root tasks should chown it to this UID to allow for him to read -->
  48. </project>
  49. </echoxml>
  50. <chown file="${p5build_SE.SYSTEM.config_dir}/build.p5build_SE.SYSTEM.local-root.xml" owner="${p5build_SE.SYSTEM.local-user}" failonerror="false"/>
  51. </target>
  52. <target name="p5build_SE.SYSTEM.StandardOutPath" if="p5build_SE.SYSTEM.StandardOutPath.notcreated">
  53. <mkdir dir="${p5build_SE.SYSTEM.StandardOutPath}"/>
  54. <chown file="${p5build_SE.SYSTEM.StandardOutPath}" owner="${p5build_SE.SYSTEM.local-user}" failonerror="false"/>
  55. <chmod file="${p5build_SE.SYSTEM.StandardOutPath}" perm="777" failonerror="false"/>
  56. </target>
  57. <target name="p5build_SE.SYSTEM.StandardErrorPath" if="p5build_SE.SYSTEM.StandardErrorPath.notcreated">
  58. <mkdir dir="${p5build_SE.SYSTEM.StandardErrorPath}"/>
  59. <chown file="${p5build_SE.SYSTEM.StandardErrorPath}" owner="${p5build_SE.SYSTEM.local-user}" failonerror="false"/>
  60. <chmod file="${p5build_SE.SYSTEM.StandardErrorPath}" perm="777" failonerror="false"/>
  61. </target>
  62. </project>