Loading

Including domain metadata in the deployment package will change the HTTPS option of the custom domain to 'No HTTPS'

Fecha de publicación: Nov 3, 2023
Descripción
  • When you have an Experience Site in production which is hosted on a Custom Domain with 'Salesforce Cloud' as a HTTPS option and Sandbox is refreshed from Production, the CustomSite metadata that is copied to the target sandbox contains a reference to the production domain minus the certificate. In UI, we still see 'Salesforce Cloud' as the HTTPS option. When you inspect the metadata of the CustomSite the reference to the CustomDomain in the customWebAddress element looks like this (notice the missing certificate element):
    <customWebAddresses>
        <domainName>**your custom domain**</domainName>
        <primary>true</primary>
    </customWebAddresses>
  • When you deploy this CustomSite metadata to any environment (sandbox or prod), it causes the domain to switch from the 'Salesforce Cloud' option to the “No HTTPS (Temporary)” option.
Solución
Option 1(Preferred):
  • The domain metadata are copies of the domain used to serve the production variation of the site. They exist in a lower environment only because they were refreshed from production.
  •  You would need to correct the domain to the intended option in a post-deployment step. Otherwise, you should avoid deploying the CustomSite metadata if it doesn’t contain any changes.

Option 2:
1. Modify the domain metadata in your deployment package 'CustomSite' that has '<customWebAddresses>' with <certificate> element like below.

<customWebAddresses>
<certificate>** certificate unique name ** </certificate>
<domainName>www.testing123.com</domainName>
<primary>true</primary>
</customWebAddresses>

2. Deploy this to your affected sandbox


NOTE: In order for the deployment to be successful, the certificate used for a domain has to match the CN or SANs of the Production certificate. This means a self-signed certificate won't work.

You will have to either refresh your Sandbox from the Production to get a copy of your Production certificates. OR you would have to import the original JKS certificate.

 

 

Número del artículo de conocimiento

000396704

 
Cargando
Salesforce Help | Article