WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud
  • Tanzu
    • Application Modernization
    • Tanzu services
    • Tanzu Community Edition
    • Tanzu Kubernetes Grid
    • vSphere with Tanzu
  • Home Lab
  • Nested Virtualization
  • Apple
You are here: Home / Not Supported / Customizing the NSX-T Login UI

Customizing the NSX-T Login UI

10.29.2019 by William Lam // 1 Comment

I have been doing some automation with NSX-T 2.5 lately and for troubleshooting and validation purposes, I obviously make use of the NSX-T UI. After each new deployment I need to login to verify a few things. Out of pure laziness, I really would like to be able to login with just a single click for development purposes. I certainly could use password manager but it would still be a couple of clicks but I was looking something slightly quicker and that could easily work in a number of environments that I have.

Looking around the filesystem of the NSX Unified Appliance, I found the structure for the login UI to be fairly similiar (thanks to VMware Clarity) to that of the vCenter Server Appliance (VCSA). I found that I could apply the same techniques I had used to customize the VCSA Login UI including setting up pre-filled credentials (no recommended for obvious reasons) on the NSX-T Appliance.


Disclaimer: This is not officially supported by VMware, use at your own risk. Please make sure to perform a backup of all original files prior to editing in case you need to restore back the system defaults.

If you wish to hardcode the username and/or password, you will need to login as root and modify /opt/vmware/proxy-tomcat/webapps/ROOT/login.jsp and below is an example:

<input class="username" type="text" id="username" name="j_username" autocomplete="off"
     placeholder="<%=resource.getString("username.placeholder.label")%>" value="admin">
<input class="password" type="password" id="password" name="j_password" autocomplete="off"
     placeholder="<%=resource.getString("password.placeholder.label")%>" value="VMware1!VMware1!">

If want your changes to persist a reboot, you will need to extract /opt/vmware/proxy-tomcat/webapps/ROOT.war and make the changes and repackage the WAR file.

While I was at this, I figure why not update the boring background as well? 🙂 This is certainly a be a bit more involved, especially as the CSS file contents are minify to a single line which you will need to un-minify. If you wish to play around with the login UI background, you can take a look at /opt/vmware/proxy-tomcat/webapps/ROOT/reverse-proxy/styles/clarity-ui.min.css and to persist the configurations, you will also need to incorporate the changes into the ROOT.war file.

More from my site

  • NSX Alarms in vCenter Server using vSphere Events in vSphere 8
  • Integrated NSX-T deployment in vSphere 7.0 Update 3 fails with timeout
  • Retrieving network statistics on VMware Cloud on AWS using NSX-T Policy API
  • Configure NSX-T Edge to run on AMD Ryzen CPU
  • NSX-T Edge OVF property to automatically join NSX-T Management Plane

Categories // Not Supported, NSX Tags // login.jsp, NSX-T

Comments

  1. Alex says

    12/31/2019 at 3:00 pm

    How to change the default background image? I checked the file /opt/vmware/proxy-tomcat/webapps/ROOT/reverse-proxy/styles/clarity-ui.min.css, but still don't know how to do it.

    Reply

Thanks for the comment! Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Author

William Lam is a Senior Staff Solution Architect working in the VMware Cloud team within the Cloud Infrastructure Business Group (CIBG) at VMware. He focuses on Cloud Native technologies, Automation, Integration and Operation for the VMware Cloud based Software Defined Datacenters (SDDC)

Connect

  • Email
  • GitHub
  • LinkedIn
  • RSS
  • Twitter
  • Vimeo

Recent

  • Self-Contained & Automated VMware Cloud Foundation (VCF) deployment using new VLC Holodeck Toolkit 03/29/2023
  • ESXi configstorecli enhancement in vSphere 8.0 Update 1 03/28/2023
  • ESXi on Intel NUC 13 Pro (Arena Canyon) 03/27/2023
  • Quick Tip - Enabling ESXi Coredumps to be stored on USB 03/26/2023
  • How to disable the Efficiency Cores (E-cores) on an Intel NUC? 03/24/2023

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2023

 

Loading Comments...