diff options
author | Endi S. Dewata <edewata@redhat.com> | 2014-02-25 12:01:55 -0500 |
---|---|---|
committer | Endi S. Dewata <edewata@redhat.com> | 2014-03-07 22:50:31 -0500 |
commit | b944d31ef744a220f176bf7143e727223ad6b3b1 (patch) | |
tree | 845e86128c25df494e7b5a6bd378f8074f423423 /base/server/python/pki/server/deployment/scriptlets/slot_substitution.py | |
parent | 60134cccd26eb872636427afe3fe1c07a253627f (diff) | |
download | pki-b944d31ef744a220f176bf7143e727223ad6b3b1.tar.gz pki-b944d31ef744a220f176bf7143e727223ad6b3b1.tar.xz pki-b944d31ef744a220f176bf7143e727223ad6b3b1.zip |
Direct deployment for TPS.
The deployment tool has been modified to deploy TPS directly from the
share folder. This way the TPS UI can be upgraded automatically with
RPM upgrade without having to write upgrade scripts.
For this to work, the TPS web application files cannot contain any slot
parameters. So, the cfgPath parameter has been removed from web.xml,
and the CMSStartServlet has been modified such that if the parameter is
missing it would generate a default path matching the original value in
web.xml. Also, the velocity.properties has been modified to use a fixed
value for the file.resource.loader.path parameter pointing to the share
folder.
In the future other subsystems may be modified to use the same
deployment mechanism.
Ticket #748, #752, #499
Diffstat (limited to 'base/server/python/pki/server/deployment/scriptlets/slot_substitution.py')
-rw-r--r-- | base/server/python/pki/server/deployment/scriptlets/slot_substitution.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/base/server/python/pki/server/deployment/scriptlets/slot_substitution.py b/base/server/python/pki/server/deployment/scriptlets/slot_substitution.py index a6c21e166..cc54cc49c 100644 --- a/base/server/python/pki/server/deployment/scriptlets/slot_substitution.py +++ b/base/server/python/pki/server/deployment/scriptlets/slot_substitution.py @@ -67,10 +67,16 @@ class PkiScriptlet(pkiscriptlet.AbstractBasePkiScriptlet): deployer.master_dict['pki_source_tomcat_conf'], deployer.master_dict['pki_target_tomcat_conf'], overwrite_flag=True) - deployer.file.apply_slot_substitution( - deployer.master_dict['pki_target_velocity_properties']) - deployer.file.apply_slot_substitution( - deployer.master_dict['pki_target_subsystem_web_xml']) + + # Configure web.xml and velocity.properties for each subsystem. + # For TPS this is not necessary since the files are no longer + # copied to the target location in the instance directory. + if deployer.master_dict['pki_subsystem'] != "TPS": + deployer.file.apply_slot_substitution( + deployer.master_dict['pki_target_velocity_properties']) + deployer.file.apply_slot_substitution( + deployer.master_dict['pki_target_subsystem_web_xml']) + # Strip "<filter>" section from subsystem "web.xml" # This is ONLY necessary because XML comments cannot be "nested"! # deployer.file.copy(deployer.master_dict['pki_target_subsystem_web_xml'], |