CWWKF1390E Error

There must be a reason why the repository can not be reached during image build. Without context information it is hard to guess why it works during container runtime, but not while building the image.

Can you share the command used to create the container and the command to trigger the build. Furthermore, please share the content of the Dockerfile, and if a compose file was used, its content as well.