Closed ind1go closed 4 years ago
When we implement this, it would be great to address review comment on https://github.com/IBM/cics-bundle-maven/pull/120 - if we did this we could revert the URLs in the pom to https://yourcicsurl.9080 and then override with a user property in the invoker plugin.
can we go with:
cicsbundle.username
cicsbundle.password
cicsbundle.url
cicsbundle.insecure
cicsbundle.bunddef
cicsbundle.region
cicsbundle.cicsplex
cicsbundle.csdgroup
cicsbundle.classifier
cicsbundle.bundle
?
@stewartfrancis @sophiegreen @ind1go please - keen to get this done.
Also I don't think I can address the review comment on #120 here because although the user property for cicsbundle.url
works, it will not override the url specified in the pom (you'd have to use a variable to achieve this, I think).
by implementing these variables, i was able to deploy my bundle without having any of the deployment config in my pom.xml, like this:
**mvn clean install com.ibm.cics:cics-bundle-maven-plugin:0.0.2-SNAPSHOT:deploy -Dcicsbundle.url=https://myhost:28951 -Dcicsbundle.username=USER -Dcicsbundle.password=PASS -Dcicsbundle.bunddef=DNDEMO2 -Dcicsbundle.csdgroup=DEMO -Dcicsbundle.cicsplex=CICSPLX -Dcicsbundle.region=IYCWEMW2 -Dcicsbundle.bundle=/Users/mydir/Documents/development/cics-bundle-demo/dn-demo-war/target/dn-demo-war-0.0.1-SNAPSHOT-cics-bundle.zip -Dcicsbundle.insecure=true
I haven't yet worked out if I can make use of the <dependency>
tag - I don't think I can, have to specify the bundle path. However it's interesting that we can do this.
Maven plugins permit the use of user properties, i.e. system properties that are recognised by the plugin and can be used to override its configuration. For example, from the invoker plugin:
These give flexibility to the build and allow overriding in different environments more easily.
Best practice for user properties is now to pick a prefix (
invoker
above) to namespace your properties, avoiding clashes with other plugins.