Forked from lamw/gist:a744df89a5b8aab18c2b69af9399565b
Created
December 1, 2018 01:13
-
-
Save gowatana/a82d8038c7994e317484d747e8edf461 to your computer and use it in GitHub Desktop.
Add custom color to vSphere HTML5 UI Header/Footer in vSphere 6.7 Update 1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NEW_HEADER_HEX_COLOR=006400 | |
NEW_BOTTOM_HEX_COLOR=8b0000 | |
BACKUP_FILE=/usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war.bak | |
if [ ! -e ${BACKUP_FILE} ]; then | |
cp /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war ${BACKUP_FILE} | |
fi | |
mkdir -p /root/work | |
cd /root/work | |
cp /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war . | |
unzip h5ngc.war | |
rm -f h5ngc.war | |
cat << EOF >> resources/css/NotSupported_H5ClientHacks.css | |
.main-nav HEADER{ | |
background-color:#${NEW_HEADER_HEX_COLOR} !important; } | |
bottom-panel toggle-splitter { | |
background: #${NEW_BOTTOM_HEX_COLOR} !important; } | |
EOF | |
sed -i '/--%>/a \ | |
\n <link href="resources/css/NotSupported_H5ClientHacks.css" rel="stylesheet"/>' WEB-INF/views/index.jsp | |
zip -r /root/h5ngc.war config error.jsp locales META-INF notfound.jsp plugin.xml resources webconsole.html WEB-INF | |
cd /root | |
rm -rf /root/work | |
cp /root/h5ngc.war /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/ | |
service-control --stop vsphere-ui; service-control --start vsphere-ui |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NEW_HEADER_HEX_COLOR=812990 | |
NEW_BOTTOM_HEX_COLOR=812990 | |
BACKUP_FILE=/usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war.bak | |
if [ ! -e ${BACKUP_FILE} ]; then | |
cp /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war ${BACKUP_FILE} | |
fi | |
mkdir -p /root/work | |
cd /root/work | |
cp /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/h5ngc.war . | |
unzip h5ngc.war | |
rm -f h5ngc.war | |
cat << EOF >> resources/css/NotSupported_H5ClientHacks.css | |
.main-nav HEADER{ | |
background-color:#${NEW_HEADER_HEX_COLOR} !important; } | |
bottom-panel toggle-splitter { | |
background: #${NEW_BOTTOM_HEX_COLOR} !important; } | |
EOF | |
sed -i '/--%>/a \ | |
\n <link href="resources/css/NotSupported_H5ClientHacks.css" rel="stylesheet"/>' WEB-INF/views/index.jsp | |
zip -r /root/h5ngc.war config error.jsp locales META-INF notfound.jsp plugin.xml resources webconsole.html WEB-INF | |
cd /root | |
rm -rf /root/work | |
cp /root/h5ngc.war /usr/lib/vmware-vsphere-ui/plugin-packages/root-app/plugins/ | |
service-control --stop vsphere-ui; service-control --start vsphere-ui |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
下記の投稿むけ。
vCenter 6.7 u1 の HTML5 vSphere Client をクリスマス風にしてみる。
https://communities.vmware.com/people/gowatana/blog/2018/11/30/vcsa-html5-hack