Hybris B2B Installation
Installing Hybris B2B
If we want to install B2B accelerator, we first need to run B2C recipe and then install B2B addon
Step 1
Navigate to the “< HYBRIS_HOME >/installer” directory
Step 2
Invoke the Installer with the b2c_acc recipe by entering the following command
• On Windows :
- install.bat -r b2c_acc
install.bat -r b2c_acc
• On Linux or Mac :
- ./install.sh -r b2c_acc
./install.sh -r b2c_acc
Wait for the build to get success
Step 3
In command prompt, Navigate to the “< HYBRIS_BIN_DIR >/platform “ directory.
Step 4
Set ant environment by entering the following command
• On Windows :
- setantenv.bat
setantenv.bat
• On Linux or Mac :
- . ./setantenv.sh
. ./setantenv.sh
Step 5
Run the ant modulegen command and modify the input.name and input.package parameters as per project requirement
- <!--Run the modulegen command-->
- ant modulegen -Dinput.module=accelerator -Dinput.name=mystore -Dinput.package=com.kb -Dinput.template=develop
<!--Run the modulegen command--> ant modulegen -Dinput.module=accelerator -Dinput.name=mystore -Dinput.package=com.kb -Dinput.template=develop
• input.module parameter : Configures the modulegen task to use the accelerator module.
• input.name value : Indicates the prefix that is added to the new extensions generated by modulegen.
• input.package value : Defines the default Java package prefix.
• input.template parameter : Defines how to use the default Hybris configuration
Step 6
After running the ant modulegen command successfully, open the ” localextensions.xml ” file located in
“< HYBRIS_HOME >/hybris/config” folder.
Step 7
Add the new extensions generated by modulegen to the “localextensions.xml” file
- <extension name="mystorefulfilmentprocess"/>
- <extension name="mystorecockpits"/>
- <extension name="mystorecore"/>
- <extension name="mystorefacades"/>
- <extension name="mystoretest"/>
- <extension name="mystoreinitialdata"/>
- <extension name="mystorestorefront"/>
<extension name="mystorefulfilmentprocess"/> <extension name="mystorecockpits"/> <extension name="mystorecore"/> <extension name="mystorefacades"/> <extension name="mystoretest"/> <extension name="mystoreinitialdata"/> <extension name="mystorestorefront"/>
Step 8
As instructed in the console output, remove the following extensions which are present in your “localextensions.xml” file
yacceleratorcore yacceleratorfacades yacceleratorstorefront yacceleratorinitialdata yacceleratortest yacceleratorcockpits yacceleratorfulfilmentproces
Step 9
Add the following B2B Accelerator extensions to the “localextensions.xml” file
- <extension name='powertoolsstore' />
- <extension name='b2bcommercebackoffice' />
- <extension name='b2badmincockpit' />
- <extension name='b2bacceleratoraddon' />
- <extension name='commerceorgaddon' />
<extension name='powertoolsstore' /> <extension name='b2bcommercebackoffice' /> <extension name='b2badmincockpit' /> <extension name='b2bacceleratoraddon' /> <extension name='commerceorgaddon' />
Step 10
Install the B2B Accelerator AddOns on the mystore storefront by running the following ant command from the
“< HYBRIS_BIN_DIR >/platform “ folder
- <!--Command to install the AddOns-->
- ant addoninstall -Daddonnames="b2bacceleratoraddon" -DaddonStorefront.yacceleratorstorefront="mystorestorefront"
- ant addoninstall -Daddonnames="commerceorgaddon" -DaddonStorefront.yacceleratorstorefront="mystorestorefront"
<!--Command to install the AddOns--> ant addoninstall -Daddonnames="b2bacceleratoraddon" -DaddonStorefront.yacceleratorstorefront="mystorestorefront" ant addoninstall -Daddonnames="commerceorgaddon" -DaddonStorefront.yacceleratorstorefront="mystorestorefront"
Step 11
Add the following properties to “ < HYBRIS_HOME >/hybris/config/local.properties “ file
- website.powertools.http=http://powertools.local:9001/mystorestorefront
- website.powertools.https=https://powertools.local:9002/mystorestorefront
website.powertools.http=http://powertools.local:9001/mystorestorefront website.powertools.https=https://powertools.local:9002/mystorestorefront
Step 12
Build & initialize Hybris Commerce by running the ant initialize from the “< HYBRIS_BIN_DIR >/platform“ folder
Step 13
Start the Hybris server by running the following command from the “< HYBRIS_BIN_DIR >/platform” folder
On Windows :
- hybrisserver.bat
hybrisserver.bat
On Linux or Mac :
- ./hybrisserver.sh
./hybrisserver.sh
Step 14
Add the following entry in your computer’s hosts file
- 127.0.0.1 powertools.local
127.0.0.1 powertools.local
Step 15
Once the server is started, access B2B Accelerator powertools storefront
https://powertools.local:9002/mystorestorefront/powertools/en/USD.
Hi KB,
b2c_acc is removed in 1905 as per https://help.sap.com/viewer/c5613bd3cc9942efb74d017b40eb0892/1905/en-US/93f848b153934721bfb3902e5cf6af3c.html
how do we do OOTB setup now?
Try this directly
install.bat -r b2b_acc_plus initialize
there is no need to uninstall node only removing it from path is sufficient.
which version of hybris you have used for setup. please let me known
Hie….The article is very good..Its work for me..But I have doubt I installed B2C also in first step as per above tutorail..So I wanted to know URL of B2C ..so can u tell me url of B2C?
we have b2b receipe y should we use b2c?
Hi KB,
Even i too having same doubt. Kindly explain why should we use b2c instead of b2b receipe?
Thanks in advance.
Hi Kb, I am getting below and build is getting failed while running ant initialize:
[echo] building extension ‘smartedit’…
[echo] START of calling grunt packageSkipTests on C:\tutorial\hybris\bin\ext-content\smartedit
[echo] failonerror=NOT SET, default=true, value=true
[echo] Running grunt packageSkipTests
[exec] Loading “grunt-karma.js” tasks…[31mERROR[39m
[exec] [31m>> [39mTypeError: Cannot read property ‘prototype’ of undefined
[exec]
[exec] [4mRunning “jshint:all” (jshint) task[24m
[exec] [33mWarning: The “path” argument must be of type string. Received type object Use –force to continue.[39m
[exec]
[exec] [31mAborted due to warnings.[39m
i had the same issue….uninstalling node fixed it
Hi,
The explanation is very nice.
i just have on doubt i followed the steps as mentioned above for “Installing Hybris B2B”
but once the server is up, and when i am hitting the mystorefront i m getting
“404 – Page does not exist” and its showing over hac page.
i did all steps mentioned above for 5.7 hybris code
and i did update running system too, but didn’t work out could you please tell me where i am going wrong.
Thanks,
Gaurav
Thank you Kb.you are doing a great job… Please provide the data hub related topics as well that will help many people