The development documentation (DEVELOPMENT.md) for using the docker container test workflow for POSIX user impersonation tests was not clear/accurate
The scripting for using the docker container tests was not compatible with modern Docker. Attempting to build the LDAP docker image with Docker 25.x failed because it could not write to /etc/hosts which is mounted as read-only.
What was the solution? (How)
Fixed up the documentation to clarify that developers should first attempt using the docker container test workflow. If that is not possible (e.g. unable to use Docker), then developers should inspect the Dockerfiles and replicate the setup on their development machine
Switched to using the BUILDKIT_SANDBOX_HOSTNAME (ref docs) to specify the container hostname at build-time. Buildkit is the new default container image build backend for Docker version 23.0 and newer.
What is the impact of this change?
Developers able to use more modern versions of Docker (≥ 23.0)
What was the problem/requirement? (What/Why)
DEVELOPMENT.md
) for using the docker container test workflow for POSIX user impersonation tests was not clear/accurate/etc/hosts
which is mounted as read-only.What was the solution? (How)
BUILDKIT_SANDBOX_HOSTNAME
(ref docs) to specify the container hostname at build-time. Buildkit is the new default container image build backend for Docker version 23.0 and newer.What is the impact of this change?
Developers able to use more modern versions of Docker (≥ 23.0)
How was this change tested?
See DEVELOPMENT.md for information on running tests.
Was this change documented?
The relevant developer documentation was updated:
DEVELOPMENT.md
testing_containers/ldap_sudo_environment/README.md
Is this a breaking change?
No
Does this change impact security?
No
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.