3

In the web.config file of DXA you can specify a cid-localhost setting. This setting is commented as follows:

Use the setting below if you need to map localhost to a specific hostname so the CID service can access resources. On some environments localhost may not resolve correctly to the external hostname.

I don't understand why you would need to map localhost to something else. Why does the CID service need to access resources on the application server? Surely it just returns the requested binaries? Or is there more to it?

How does this setting get used? When would you configure it, and what value would it make sense to use?

5

The CID Service obtains the original images from the Web Application; for that purpose, the Web Application passes a reference to itself in the CID request URLs.

By default, it passes the authority used in the original request (i.e. the request for the Page which contains CID image URLs), but this strategy won't work if the original request is on localhost, but the CID service runs on a different box.

To make such scenarios work, there is special handling for localhost requests: you can configure the hostname to send to the CID service if the original Request is for localhost.

| improve this answer | |
  • Aha... that's what I was missing. I'd assumed that the CID service was similar to the content service, just with some extra goodness for resizing. Perhaps I was fooled by "delivery" in the name. In any case, this is also helpful to know, in that I will start by testing that the original image is correctly served. Thanks. – Dominic Cronin Aug 1 '16 at 19:36
  • I now see that this is mentioned as a known issue docs.sdl.com/LiveContent/content/en-US/SDL%20DXA-v5/… – Dominic Cronin Aug 2 '16 at 9:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.