1

We'd like to enable the Sitecore Federated Authentication on Sitecore 10.2 with containers. I've updated the ClientId, TenantId, claim transfermations, etc... in different xml files. But I don't know how to deploy those files into the Identity Server container.

1 Answer 1

2

You would need to build a custom Sitecore image for the Identity Server: https://doc.sitecore.com/xp/en/developers/102/developer-tools/building-custom-sitecore-images.html

You need a project with your custom files that you can build in your solution Dockerfile (with msbuild) just like the platform build which is probably already there.

Then you need to change the Dockerfile for the ID to copy the files from that artifact (and change the docker-compose-override to pass the necessary arguments). This ID Dockerfile could be something like:

# escape=`

ARG PARENT_IMAGE
ARG SOLUTION_IMAGE

FROM ${SOLUTION_IMAGE} as solution
FROM ${PARENT_IMAGE}
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
WORKDIR C:\Identity
# Copy identity artifacts
COPY --from=solution /artifacts/identity/ ./
ENTRYPOINT ["dotnet", "Sitecore.IdentityServer.Host.dll"]
3
  • Thanks for the information. But I only got 2 xml files to deploy. Do I still need to create a project and execute the build? Can I just "copy" those 2 files while the IS container starts?
    – Ray Zhang
    Jun 16, 2022 at 6:46
  • No, you should really do this the right way. It's really not that much work. You can copy those files but that is just crappy and not maintainable.
    – Gatogordo
    Jun 16, 2022 at 7:24
  • thanks for that. Much appreciated!
    – Ray Zhang
    Jun 17, 2022 at 10:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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