diff --git a/.travis.yml b/.travis.yml index f01918e..e6c1a7c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,7 +7,7 @@ deploy: provider: releases api_key: secure: W8QeU+nMpQPKDfDKSdcGMx09NRn5Ggd6mgIgpZbAp9+BpDKjDKnxlhCRz3lhGsJJB4U6PMwMj0ywyriudmcVZGZMxddGxYYSXPSvw2bCAO0Kgblt+UiHtdDxhEJOv5CpRXNoB51OEoJopOVUFTbahjqqcARZoh0a0xCp48mru1hB3vQe76HgHk1gk7F3hv/3YWJsMCKPFOzo93Nlg5Jnph8uzAV2BMdIaTUwNcCF/tZ9qO6MtJXmHVBGpCrhF6UWoZHBJ2ky4BBVuvS5e/pvToCGbc3/CVPOARZRqeFR5FcpfHsJp29tZ5FVjc0EXlwrKiTkvud1vmvDOL57bo4wdTdwJ8t+vI6HuJt8tICSMba1aY19+47w9o0o3336qXzm9wLB/AyeItXH4lO+wTTFzl9Qsyps5nkJ7d1r799yCDhLwOEeRQmk6dxK42sxuY2KrxEP3di3bDU1udso0PDFp2OOE74y1QKzRiRj909oil5DAkA8Jnnm2MglBHNUEKcIZmXYHeAqZ5cZX6d9gOPMqHX6EITHOt7pvLAMP9asnVwc395Cjp3Ol3nZ4uycL0MmaoPQ7hcgX7uIgHRI9VqPyQ1sqnjlJ9TkSNTzXU+vt9yskgeuRxygaaOom1e0+XbvFjueU7kCx61HcwyhwQmByXgSYD5d4wm1ECeNrJXM95U= - file: build/distributions/xld-datical-plugin-1.5.1.xldp + file: build/distributions/xld-datical-plugin-1.5.2.xldp on: all_branches: true tags: true diff --git a/build.gradle b/build.gradle index 2bce7c6..ac9226c 100644 --- a/build.gradle +++ b/build.gradle @@ -19,7 +19,7 @@ apply plugin: 'idea' apply plugin: 'eclipse' apply plugin: 'maven' -version="1.5.1" +version="1.5.2" processResources.configure { filter ReplaceTokens, tokens: [ diff --git a/src/main/resources/datical/datical_deploy.bat.ftl b/src/main/resources/datical/datical_deploy.bat.ftl index 31a72cd..4b35c43 100755 --- a/src/main/resources/datical/datical_deploy.bat.ftl +++ b/src/main/resources/datical/datical_deploy.bat.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} deploy ${deployed.envName} <#if deployed.labels?has_content>--labels="${deployed.labels}" <#if deployed.reportsLocation?has_content>--report="${deployed.reportsLocation}" +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} deploy ${deployed.envName} ${labels} ${reports} diff --git a/src/main/resources/datical/datical_deploy.sh.ftl b/src/main/resources/datical/datical_deploy.sh.ftl index 31a72cd..4b35c43 100755 --- a/src/main/resources/datical/datical_deploy.sh.ftl +++ b/src/main/resources/datical/datical_deploy.sh.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} deploy ${deployed.envName} <#if deployed.labels?has_content>--labels="${deployed.labels}" <#if deployed.reportsLocation?has_content>--report="${deployed.reportsLocation}" +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} deploy ${deployed.envName} ${labels} ${reports} diff --git a/src/main/resources/datical/datical_forecast.bat.ftl b/src/main/resources/datical/datical_forecast.bat.ftl index 181d9c1..bbf500b 100755 --- a/src/main/resources/datical/datical_forecast.bat.ftl +++ b/src/main/resources/datical/datical_forecast.bat.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} forecast ${deployed.envName} <#if deployed.labels?has_content>--labels="${deployed.labels}" <#if deployed.reportsLocation?has_content>--report="${deployed.reportsLocation}" +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} forecast ${deployed.envName} ${labels} ${reports} diff --git a/src/main/resources/datical/datical_forecast.sh.ftl b/src/main/resources/datical/datical_forecast.sh.ftl index 181d9c1..bbf500b 100755 --- a/src/main/resources/datical/datical_forecast.sh.ftl +++ b/src/main/resources/datical/datical_forecast.sh.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} forecast ${deployed.envName} <#if deployed.labels?has_content>--labels="${deployed.labels}" <#if deployed.reportsLocation?has_content>--report="${deployed.reportsLocation}" +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} forecast ${deployed.envName} ${labels} ${reports} diff --git a/src/main/resources/datical/datical_generic.ftl b/src/main/resources/datical/datical_generic.ftl new file mode 100644 index 0000000..264f6e6 --- /dev/null +++ b/src/main/resources/datical/datical_generic.ftl @@ -0,0 +1,5 @@ +<#assign login>${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.envName}:::${deployed.container.username} -pw ${deployed.envName}:::${deployed.container.password} + +<#assign labels><#if deployed.labels?has_content>--labels="${deployed.labels}" + +<#assign reports><#if deployed.reportsLocation?has_content>--report="${deployed.reportsLocation}" diff --git a/src/main/resources/datical/datical_status_detail.bat.ftl b/src/main/resources/datical/datical_status_detail.bat.ftl index 27a22f3..a0c8a96 100755 --- a/src/main/resources/datical/datical_status_detail.bat.ftl +++ b/src/main/resources/datical/datical_status_detail.bat.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} statusDetails ${deployed.envName} +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} statusDetails ${deployed.envName} diff --git a/src/main/resources/datical/datical_status_detail.sh.ftl b/src/main/resources/datical/datical_status_detail.sh.ftl index 27a22f3..a0c8a96 100755 --- a/src/main/resources/datical/datical_status_detail.sh.ftl +++ b/src/main/resources/datical/datical_status_detail.sh.ftl @@ -10,4 +10,5 @@ --> -${deployed.container.home} <#if deployed.container.username?has_content>-un ${deployed.container.username} -pw ${deployed.container.password} -p ${deployed.targetPath} statusDetails ${deployed.envName} +<#include "/datical/datical_generic.ftl"> +${login} -p ${deployed.targetPath} statusDetails ${deployed.envName} diff --git a/src/main/resources/datical/datical_undeploy.bat.ftl b/src/main/resources/datical/datical_undeploy.bat.ftl index 1335789..1c5d9f4 100755 --- a/src/main/resources/datical/datical_undeploy.bat.ftl +++ b/src/main/resources/datical/datical_undeploy.bat.ftl @@ -12,8 +12,8 @@ <#if previousDeployed.changeids?size gt 0> <#list previousDeployed.changeids as changeid> - ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.container.username} -pw ${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} changeid:id=${changeid} + ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.envName}:::${previousDeployed.container.username} -pw ${previousDeployed.envName}:::${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} changeid:id=${changeid} <#else> -${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.container.username} -pw ${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} lastdeploy +${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.envName}:::${previousDeployed.container.username} -pw ${previousDeployed.envName}:::${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} lastdeploy diff --git a/src/main/resources/datical/datical_undeploy.sh.ftl b/src/main/resources/datical/datical_undeploy.sh.ftl index 3e75999..6a52385 100755 --- a/src/main/resources/datical/datical_undeploy.sh.ftl +++ b/src/main/resources/datical/datical_undeploy.sh.ftl @@ -12,8 +12,8 @@ <#if previousDeployed.changeids?size gt 0> <#list previousDeployed.changeids as changeid> - ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.container.username} -pw ${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} changeid:id=${changeid} + ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.envName}:::${previousDeployed.container.username} -pw ${previousDeployed.envName}:::${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} changeid:id=${changeid} <#else> - ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.container.username} -pw ${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} lastdeploy + ${previousDeployed.container.home} <#if previousDeployed.container.username?has_content>-un ${previousDeployed.envName}:::${previousDeployed.container.username} -pw ${previousDeployed.envName}:::${previousDeployed.container.password} -p ${previousDeployed.targetPath} rollback ${previousDeployed.envName} lastdeploy