- Once you browse Pages app (pages.sitecorecloud.io), go to browser developer tools --> Application --> Storage --> Local Storage and open the entry for https://pages.sitecorecloud.io.
- Add a new key and value.
- Key: Sitecore.Pages.LocalXmCloudUrl
- Value: Your local XM Cloud CM instance. Ex: https://xmcloudcm.localhost/
- Refresh the pages app and it should connect to your local XM cloud instance.
- login.sitecorecloud.io refused to connect or couldn't retrieve the page.
This happens when your local XM Cloud instance is not logged in. Make sure you login to use local XM Cloud instance in the same browser (another tab) and this error should go away. - Pages app does not render the content and components from local XM Cloud instance
Looking at the console log, a possible certificate exception appeared.In the environment file, the public rendering host is www.xmcloudpreview.localhost. The Pages app is using https://xmcloudcm.localhost as the local XM Cloud URL, as we set it in the local storage key Sitecore.Pages.LocalXmCloudUrl. Then, the local XM Cloud instance calls the public rendering host and gets the content. However, the local XM Cloud instance does not have a valid certificate for the public rendering host www.xmcloudpreview.localhost.
Once the certificate was created and placed in the \docker\traefik\certs folder and the config \docker\traefik\config\dynamic\certs_config.yaml was added, the rendering host public URL started working without any certificate errors and the pages app was also able to render the page for editing.
Go to \docker\traefik\certs, run mkcert www.xmcloudpreview.localhost and it will create the cert and key. You can refer it in certs_config.yaml and restart the rendering container alone.
I am looking for other options or solutions which can fix this issue. If this is the only way, Sitecore can add it as part of their initial XM Cloud local instance setup itself.
No comments:
Post a Comment