summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEndi Sukma Dewata <edewata@redhat.com>2012-11-05 15:59:44 -0500
committerEndi Sukma Dewata <edewata@redhat.com>2012-11-05 17:53:55 -0500
commitbe140e1b2b35c23f70de9ee9bf4346a42ee61adb (patch)
tree407f6f94a49ed6d2e95e5c3238ab291c57ed8231
parenta26b52824f8ecc513f199853228414c384cb3cbc (diff)
downloadpki-be140e1b2b35c23f70de9ee9bf4346a42ee61adb.zip
pki-be140e1b2b35c23f70de9ee9bf4346a42ee61adb.tar.gz
pki-be140e1b2b35c23f70de9ee9bf4346a42ee61adb.tar.xz
Removed images and CSS files from subsystem webapp.ticket-328-4
Since all paths to the theme images and CSS files have been updated, it's no longer necessary to copy these files into subsystem's web application. The deployment tool will still need copy the Velocity templates. Ticket #328
-rw-r--r--base/deploy/src/scriptlets/webapp_deployment.py68
-rwxr-xr-xbase/setup/pkicreate18
2 files changed, 77 insertions, 9 deletions
diff --git a/base/deploy/src/scriptlets/webapp_deployment.py b/base/deploy/src/scriptlets/webapp_deployment.py
index 507d23c..28aa31d 100644
--- a/base/deploy/src/scriptlets/webapp_deployment.py
+++ b/base/deploy/src/scriptlets/webapp_deployment.py
@@ -44,14 +44,42 @@ class PkiScriptlet(pkiscriptlet.AbstractBasePkiScriptlet):
return self.rv
config.pki_log.info(log.WEBAPP_DEPLOYMENT_SPAWN_1, __name__,
extra=config.PKI_INDENTATION_LEVEL_1)
- # deploy war file
+
+ # deploy webapp
util.directory.create(master['pki_tomcat_webapps_subsystem_path'])
+
+ # Copy /usr/share/pki/common-ui/admin/console/config
+ # to <instance>/webapp/<subsystem>/admin/console/config
util.directory.copy(
os.path.join(
config.PKI_DEPLOYMENT_SOURCE_ROOT,
- "common-ui"),
- master['pki_tomcat_webapps_subsystem_path'],
+ "common-ui",
+ "admin",
+ "console",
+ "config"),
+ os.path.join(
+ master['pki_tomcat_webapps_subsystem_path'],
+ "admin",
+ "console",
+ "config"),
overwrite_flag=True)
+
+ # Copy /usr/share/pki/common-ui/admin/console/js
+ # to <instance>/webapp/<subsystem>/admin/console/js
+ util.directory.copy(
+ os.path.join(
+ config.PKI_DEPLOYMENT_SOURCE_ROOT,
+ "common-ui",
+ "admin",
+ "console",
+ "js"),
+ os.path.join(
+ master['pki_tomcat_webapps_subsystem_path'],
+ "admin",
+ "console",
+ "js"),
+ overwrite_flag=True)
+
util.directory.copy(
os.path.join(
config.PKI_DEPLOYMENT_SOURCE_ROOT,
@@ -105,14 +133,42 @@ class PkiScriptlet(pkiscriptlet.AbstractBasePkiScriptlet):
if master['pki_subsystem'] in config.PKI_TOMCAT_SUBSYSTEMS:
config.pki_log.info(log.WEBAPP_DEPLOYMENT_RESPAWN_1, __name__,
extra=config.PKI_INDENTATION_LEVEL_1)
- # redeploy war file
+
+ # redeploy webapp
util.directory.modify(master['pki_tomcat_webapps_subsystem_path'])
+
+ # Copy /usr/share/pki/common-ui/admin/console/config
+ # to <instance>/webapp/<subsystem>/admin/console/config
util.directory.copy(
os.path.join(
config.PKI_DEPLOYMENT_SOURCE_ROOT,
- "common-ui"),
- master['pki_tomcat_webapps_subsystem_path'],
+ "common-ui",
+ "admin",
+ "console",
+ "config"),
+ os.path.join(
+ master['pki_tomcat_webapps_subsystem_path'],
+ "admin",
+ "console",
+ "config"),
overwrite_flag=True)
+
+ # Copy /usr/share/pki/common-ui/admin/console/js
+ # to <instance>/webapp/<subsystem>/admin/console/js
+ util.directory.copy(
+ os.path.join(
+ config.PKI_DEPLOYMENT_SOURCE_ROOT,
+ "common-ui",
+ "admin",
+ "console",
+ "js"),
+ os.path.join(
+ master['pki_tomcat_webapps_subsystem_path'],
+ "admin",
+ "console",
+ "js"),
+ overwrite_flag=True)
+
util.directory.copy(
os.path.join(
config.PKI_DEPLOYMENT_SOURCE_ROOT,
diff --git a/base/setup/pkicreate b/base/setup/pkicreate
index 7679607..b5a9047 100755
--- a/base/setup/pkicreate
+++ b/base/setup/pkicreate
@@ -2124,9 +2124,21 @@ sub process_pki_directories
$default_dir_permissions, $default_file_permissions,
$pki_user, $pki_group);
- return 0 if !copy_directory($common_ui_subsystem_path, $webapps_subsystem_instance_path,
- $default_dir_permissions, $default_file_permissions,
- $pki_user, $pki_group);
+ # Copy /usr/share/pki/common-ui/admin/console/config
+ # to <instance>/webapp/<subsystem>/admin/console/config
+ return 0 if !copy_directory(
+ "$common_ui_subsystem_path/admin/console/config",
+ "$webapps_subsystem_instance_path/admin/console/config",
+ $default_dir_permissions, $default_file_permissions,
+ $pki_user, $pki_group);
+
+ # Copy /usr/share/pki/common-ui/admin/console/js
+ # to <instance>/webapp/<subsystem>/admin/console/js
+ return 0 if !copy_directory(
+ "$common_ui_subsystem_path/admin/console/js",
+ "$webapps_subsystem_instance_path/admin/console/js",
+ $default_dir_permissions, $default_file_permissions,
+ $pki_user, $pki_group);
return 0 if !copy_directory($ui_subsystem_path, $pki_instance_path,
$default_dir_permissions, $default_file_permissions,