-
Notifications
You must be signed in to change notification settings - Fork 3
Home
Welcome to the CoreMedia Magento integration wiki!
This module is a guide to integrating CoreMedia LiveContext with Magento Commerce system. For more information, see the repository README.
The documentation on the Magento Installation page describes how to install a Magento Commerce system in Version 2. This tutorial uses a basic installation of Magento including the Luma storefront provided as demo content within Magento.
This guide will also walk you through the installation of the CoreMedia widgets in the Magento system. These widgets will make it possible to add CoreMedia content to your Magento pages.
The code in this repository contains an extension to CoreMedia LiveContext which enables CoreMedia customers to access and enhance Magento content within the CoreMedia Studio. The installation instructions for a clean CoreMedia LiveContext workspace with the Magento extension can be found here: CoreMedia Magento Extension Installation.
If you already have a CoreMedia LiveContext workspace, please see our documentation for enabling extensions. We've provided a chef cookbook for this extension to set the necessary properties for Magento in the CoreMedia applications.
Even if you do not yet have a CoreMedia LiveContext workspace, you can still add some test CoreMedia fragments into your Magento system to see how the integration works on the Magento side. We've provided a testsytem with fragments that you can insert into your Magento system via the CoreMedia widgets in this repository. Follow the Magento Intstallation guide to install the widgets using the testsystem configuration.
- Follow Magento Installation with CoreMedia Widget and Magento Installation.
- Complete the Apache HTTPD configuration for SSL according to the Wiki page Magento Installation and the centOS Wiki. Note that the SSL config given in the Wiki is just a snippet that is to be included in a fully-fledged VirtualHost configuration for SSL.
- After installing MySQL change root password in MySQL shell (including allowance for weak passwords - 8 chars min):
SET GLOBAL validate_password_policy=LOW;
alter user 'root'@'localhost' identified by '***';
- Navigate to the admin interface at https://www.example.com/admin_pim7zv. Log in with admin / Coremedia@2017.
- Access the Magento demo site at http://www.example.com.
- Checkout https://github.com/CoreMedia/coremedia-magento-integration.git
- Copy the Magento connector (module magento-connector in the checked-out sources). Make sure the following folder contents exist in /var/www/html/example.com/public_html/app/code:
drwxr-xr-x 3 magento apache 26 Dec 4 08:50 CoreMedia
-rw-r--r-- 1 magento apache 1177 Dec 4 08:50 coremedia_widget_instance_export.sql
- In the LC3 workspace create a module modules/extensions/magento and copy the other folders plus pom.xml from the checked-out sources to this new folder.
- Add magento to managed-extensions.txt and run
mvn dependency:copy -Dartifact=com.coremedia.tools.extensions:extensions:1.6:jar:all -DlocalRepositoryDirectory=extensions-tool -Dtransitive=false -DoutputDirectory=tool -Dmdep.stripVersion=true -Dmdep.stripClassifier=true
java -jar tool/extensions.jar --task synchronize --extension-config-file workspace-configuration/extensions/extension-config.properties --task-input-file workspace-configuration/extensions/managed-extensions.txt
- Provide an adapted node definition for LC deployment:
{
"blueprint": {
"hostname": "cm9",
"loopback_hostname": "localhost",
"maven_repository_url": "file://localhost/tmp/maven-repo",
"tomcat": {
"java_home": "/opt/jdk1.8.0_131"
},
"tools": {
"java_home": "/opt/jdk1.8.0_131"
},
"solr": {
"java_home": "/opt/jdk1.8.0_131"
},
"webapps": {
"content-management-server": {
"application.properties": {
"cap.server.license": "properties/corem/license.zip"
}
},
"master-live-server": {
"application.properties": {
"cap.server.license": "properties/corem/license.zip"
}
}
},
"livecontext": {
"magento": {
"host": "192.168.33.150",
"user": "admin",
"password": "CoreMedia@2017",
"basePath": "/rest",
"admin_uri": "/admin_pim7zv",
"application.properties": {
"livecontext.cookie.domain": ".DOMAIN"
}
}
},
"dev": {
"content": {
"content_zip": "file://localhost/tmp/content-users.zip"
}
}
},
"run_list": [
"role[mysql]",
"role[mongodb]",
"role[lc3-magento-config]",
"role[solr]",
"role[management]",
"role[publication]",
"role[preview]",
"role[preview-proxy]",
"role[lc3-magento-preview-proxy]",
"role[studio]",
"role[studio-proxy]",
"role[delivery]",
"role[lc3-magento-delivery-proxy]",
"recipe[blueprint-lc3-magento::overview]",
"recipe[blueprint-lc3-magento::test-data-config]",
"recipe[blueprint-dev-tooling::content]"
]
}
- Import the Luma demo content onto your box:
/opt/coremedia/content-management-server-tools/bin/cm serverimport -u admin -p admin -r content/