SalesforceCommerceCloud / b2c-crm-sync

... a contemporary perspective on how to integrate B2C Commerce and the Salesforce Customer 360 Platform to power frictionless customer experiences in the B2C domain.
https://salesforcecommercecloud.github.io/b2c-crm-sync/
BSD 3-Clause "New" or "Revised" License
64 stars 47 forks source link

[BUG] Error on crm-sync:b2c:build #143

Closed freytagt closed 2 years ago

freytagt commented 2 years ago

We want to do the crm-sync:b2c:build command to a production environment of SFCC but this fails. The Connection to SFCC with the credentials in the .env seem to work as we can get a Token and were able to pull Sites & Customerlists.

Sadly there is only the Message: -- Unable to upload the meta-data archive

Screnshots: Bildschirmfoto 2022-03-16 um 09 37 02

Bildschirmfoto 2022-03-16 um 09 36 29

Your local environment details:

Additional context We deployed all Metadata to CRM manually and not with the deployment process. We prepared everything for it. As last step to activate the Connector we need the crm-sync:b2c:build process, as it builds and deploys the Metadata and Code to SFCC. But this Fails. Unfortunately this worked before on Sandbox to a Development Instance on SFCC.

freytagt commented 2 years ago

Would it be possible to exclude the deployment section in the _b2cBuild.js and see if the rest works? Or at least the Output of the results?

                // Deploy the B2C meta-data
                let deployDataResults = await cliAPI.b2cDeployData(
                    environmentDef,
                    config.get('paths.b2cLabel'),
                    config.get('paths.metadataPathLabel'));

                // Output the meta-data deployment results
                cliUi.outputResults(
                    [deployDataResults.outputDisplay.authenticate],
                    undefined,
                    'cliTableConfig.b2cAuthTokenOutput');
jbachelet commented 2 years ago

Hello,

Thank you for posting this issue.

The crm-sync CLI commands are not intended to be used against a production instance, both B2C or Core platform. These commands are there to ease the setup on sandbox/developer/scratch orgs, so that you guys can install crm-sync fastly.

When deploying to production instances, we strongly recommend using your existing build logic to deploy to B2C Commerce and the Core Platform, and not the CLI commands from this repository.

Also note that B2C Commerce, on production, requires a 2FA authentication to deploy code and metadata, which is not supported by the CLI commands from crm-sync, especially because these ones should not be used against a production instance.

Closing this issue as it is not a bug Thanks.