OpenJobDescription / openjd-sessions-for-python

Provides a Python library that can be used to build a runtime that is able to run Jobs in a Session as defined by Open Job Description.
https://github.com/OpenJobDescription/openjd-specifications/wiki
Apache License 2.0
10 stars 12 forks source link

test: upgrade docker testing compatibility to Docker 25.x #172

Closed jusiskin closed 3 weeks ago

jusiskin commented 3 weeks ago

What was the problem/requirement? (What/Why)

  1. The development documentation (DEVELOPMENT.md) for using the docker container test workflow for POSIX user impersonation tests was not clear/accurate
  2. 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)

  1. 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
  2. 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)

How was this change tested?

See DEVELOPMENT.md for information on running tests.

Was this change documented?

The relevant developer documentation was updated:

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.

sonarcloud[bot] commented 3 weeks ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud