Getting ui-components updates backported to gaprindashvili

ui

#1

The gaprindashvili release is using ManageIQ/ui-components contrained to ~1.0.0.
The release uses lockfiles to lock to specific version, so simply releasing a new version will not automatically affect the release.

Therefore, to get ui-components changes to ui-classic, one needs to:

  • create a ui-components PR with the actual changes
  • make a release of a 1.0.* version happen, using the npm+bower process
  • create a ui-classic [GAPRINDASHVILI] PR which actually updates the version used

Releasing ui-components is described in https://github.com/ManageIQ/ui-components/wiki/Releasing-a-new-version, do take care to release the bower version correctly.

Creating the ui-classic PR should simply be a matter of:

# having run bin/update after switching the branch (or rm -rf vendor/assets/bower_components ; bower install ; yarn)
yarn run bower-locker unlock
bower install manageiq-ui-components
# check the right version got installed, check git diff looks sane
yarn run bower-locker lock

(after https://github.com/ManageIQ/manageiq-ui-classic/pull/2624 is merged).

EDIT: copied to https://github.com/ManageIQ/ui-components/wiki/Getting-UI-components-updates-backported-to-Gaprindashvili for findability


#2

Hello,

I’m probably going to sound stupid but i tried to install the manageiq ui-components a couple of times but I can’t get it working.

I’ve started by going to this folder:
cd ./usr/local/lib/ruby/gems/2.3.0/bundler/gems/manageiq-ui-classic-e89a4b903985

Then i unlock it using the bower-locker as described.
After that i type the bower install manageiq-ui-components command:

Then it asks me which version i want to install, i’ve tried both, but they give the same result in my situation.

When that finishes i execute the lock command.

After that i use the command git add -Ap to patch my old ui-components folder.
When i do this it asks if i want to “stage this hunk” where i always reply with “y”.

After that i looked at my ui-components folder
cd ./opt/manageiq/manageiq-ui-service/node_modules/@manageiq/ui-components

There’s also a cached one (which i deleted but this doesn’t seem to help
cd ./usr/local/share/.cache/yarn/v1/npm-@manageiq/ui-components-1.0.12-d3e4eb342c246852802f8d70d687d54a65a20c3a/

And all the files are the same as before the patch.

I also tried deleting the ui-components folder and just git cloned the one from github
git clone https://github.com/ManageIQ/ui-components.git

But when i do this my ManageIQ doesn’t work properly anymore.

Can someone help me?
Thanks in advance.


#3

What are you actually trying to accomplish?

Is this on an appliance or in your development setup?

These instructions are for the case where you’ve released a new ui-components version and want to create a PR against ui-classic in gaprindashvili so that it will use the new version on the next build.


Updating to newer ui-components on master is as easy as yarn upgrade in manageiq-ui-service, or bin/update in manageiq-ui-classic.


#4

Thanks for the quick react.

I’m trying to get the newer version of ui-components on my test appliance.

I just tried the bin/update method:
/var/www/miq/vmdb/bin/update

But it failes:
2018-04-20_17-05-15

When i list my gems i can see the correct ones are installed

rails (5.2.0, 5.0.6)
pg (1.0.0, 0.18.4)
kubeclient (3.0.0, 2.5.2, 2.4.0)

I’m using gaprindashvili-2.20180305154841_5bba686


#5

I don’t think there’s an established process for upgrading the appliance, so I can’t help you there, sorry. (Also, no clue, maybe the versions of the other repos are fixed somewhere on the appliance?)

Also, if you’re on gaprindashvili, you need to take care to only update to ui-components 1.0.*. The 1.1.* series of releases won’t work with gaprindashvili.

(I suggest not doing development on gaprindashvili, here you can find how to set up development on your machine.)


#6

@himdel Okay, thanks for your time anyway


#7

Added a guide looking into this in more detail - https://github.com/ManageIQ/ui-components/wiki/Updating-ui-components-on-an-appliance .