commit | d87135943df315a2d376dda93afe22ccf7809b4c | [log] [tgz] |
---|---|---|
author | Ed Tanous <ed@tanous.net> | Thu Jul 16 07:33:07 2020 -0700 |
committer | Ed Tanous <ed@tanous.net> | Wed Jul 22 17:12:41 2020 -0700 |
tree | 59c398cc8f3fd85a1cf624a276cbe67ae4de506f | |
parent | 2e1eec80de6c8e9a2bd7c813c9e9ff31038e0906 [diff] |
Drop encoding library Commit f4a43cca440535a63592877c9bdbbe28636d803c attempted to fix a IE bug in the SOL library. Unfortunately, it did it by pulling in the entire NPM encoding library, which is insanely large (190kb after minification and compression). This is almost equivalent to the rest of our javascript put together! That's nuts, and I don't think anyone would argue that's a binary hit worth taking for IE9 support. This commit removes it, and swaps in an inline polyfill from the mozilla recommendations, that compresses much....much smaller. Before this patchset build prints: app.bundle.js.gz 522 KiB [emitted] [big] After this patchset: app.bundle.js.gz 332 KiB [emitted] [big] If you don't want to break out a calculator, that's 190KB savings in the root filesystem, and should cut the initial page load time (on slow connections) by nearly 30 percent. Note: text-encodings was never pinned in the package-lock.json, hence why you don't see a diff removing it from package lock. This was a miss on the original commiters part, although it doesn't really matter, as it's now removed. PS: A reviewer may note, I could've moved the polyfill into its own file. Considering the serial console is the only page that uses that, and it's not that big I elected not to, to make removing it analagous with removing xterm/the serial console. Bonus content! Added a (commented out) webpack config that allows you to generate the webui as individual gzipped fragments, instead of one bundle. This allows you to see file sizes on a package by package basis, and was how I found this commit in question. Testing: This is where this patchset gets hairy. I dont' have an IE9 instance to test on. Given it's low usage, and the fact that it's a relatively straightforward change we can probably just wait for someone to tell us it's broken again. Enjoy the sweet sweet savings. Signed-off-by: Ed Tanous <ed@tanous.net> Change-Id: I2820ff1c4b33d725ebc63490793a72fe600b8ed3 Signed-off-by: Ed Tanous <ed@tanous.net>
The OpenBMC WebUI is a Web-based user interface for the OpenBMC firmware stack. The WebUI uses AngularJS. Features include:
nodejs (>= 4.2.6) npm (>= 6.0.1)
Note The default installation of your Linux distro may not come with the required versions above. See the following for more information on updating:
https://docs.npmjs.com/troubleshooting/try-the-latest-stable-version-of-node https://docs.npmjs.com/troubleshooting/try-the-latest-stable-version-of-npm
npm install
Note This must be run from within the phosphor-webui git repository.
npm run-script server
This will start a server instance and begin listening for connections at http://localhost:8080
. This development server provides live reloading on code changes. NOTE: Browsing to https://<BMC>
and accepting the self-signed certificate might be required to prevent your browser from blocking traffic to the BMC.
Enter the BMC Host or BMC IP address, username, and password. The default username and password are root
/0penBmc
.
Note that some OpenBMC implementations use bmcweb for its backend. For security reasons, bmcweb will need to be recompiled and loaded onto the target BMC Host before the above redirect command will work. The option to turn on within bmcweb is BMCWEB_INSECURE_DISABLE_XSS_PREVENTION
. In order to test locally, you will also need to disable CSRF by turning on BMCWEB_INSECURE_DISABLE_CSRF_PREVENTION
.