Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(docker): Use Python 3.12 in docker images #10473

Draft
wants to merge 8 commits into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile.django-alpine
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Dockerfile.nginx to use the caching mechanism of Docker.

# Ref: https://devguide.python.org/#branchstatus
FROM python:3.11.9-alpine3.20@sha256:df44c0c0761ddbd6388f4549cab42d24d64d257c2a960ad5b276bb7dab9639c7 AS base
FROM python:3.12.4-alpine3.20@sha256:882ef0a4b7dcf365686ed535e120e35c465e5fed64bd378498b4a27a134ce124 AS base
FROM base AS build
WORKDIR /app
RUN \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.django-debian
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Dockerfile.nginx to use the caching mechanism of Docker.

# Ref: https://devguide.python.org/#branchstatus
FROM python:3.11.9-slim-bookworm@sha256:8c1036ec919826052306dfb5286e4753ffd9d5f6c24fbc352a5399c3b405b57e AS base
FROM python:3.12.4-slim-bookworm@sha256:9638987a16d55a28096d4d222ea267710d830b207ed1a9f0b48ad2dbf67475aa AS base
FROM base AS build
WORKDIR /app
RUN \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.integration-tests-debian
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# code: language=Dockerfile

FROM openapitools/openapi-generator-cli:v7.8.0@sha256:c409bfa9b276faf27726d2884b859d18269bf980cb63546e80b72f3b2648c492 AS openapitools
FROM python:3.11.9-slim-bookworm@sha256:8c1036ec919826052306dfb5286e4753ffd9d5f6c24fbc352a5399c3b405b57e AS build
FROM python:3.12.4-slim-bookworm@sha256:9638987a16d55a28096d4d222ea267710d830b207ed1a9f0b48ad2dbf67475aa AS build
WORKDIR /app
RUN \
apt-get -y update && \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.nginx-alpine
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Dockerfile.django-alpine to use the caching mechanism of Docker.

# Ref: https://devguide.python.org/#branchstatus
FROM python:3.11.9-alpine3.20@sha256:df44c0c0761ddbd6388f4549cab42d24d64d257c2a960ad5b276bb7dab9639c7 AS base
FROM python:3.12.4-alpine3.20@sha256:882ef0a4b7dcf365686ed535e120e35c465e5fed64bd378498b4a27a134ce124 AS base
FROM base AS build
WORKDIR /app
RUN \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.nginx-debian
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Dockerfile.django-debian to use the caching mechanism of Docker.

# Ref: https://devguide.python.org/#branchstatus
FROM python:3.11.9-slim-bookworm@sha256:8c1036ec919826052306dfb5286e4753ffd9d5f6c24fbc352a5399c3b405b57e AS base
FROM python:3.12.4-slim-bookworm@sha256:9638987a16d55a28096d4d222ea267710d830b207ed1a9f0b48ad2dbf67475aa AS base
FROM base AS build
WORKDIR /app
RUN \
Expand Down
2 changes: 1 addition & 1 deletion dojo/settings/.settings.dist.py.sha256sum
Original file line number Diff line number Diff line change
@@ -1 +1 @@
38096a82c7cdeec6ca9c663c1ec3d6a5692a0e7bbfdea8fd2f05c58f753430d4
5380e59f50d2072e6896703f6f390e5432f3557c89f432c8cbfb63de581a8cf2
3 changes: 3 additions & 0 deletions dojo/settings/settings.dist.py
Original file line number Diff line number Diff line change
Expand Up @@ -1754,6 +1754,9 @@ def saml2_attrib_map_format(dict):
warnings.filterwarnings("ignore", message="polymorphic.base.ManagerInheritanceWarning.*")
warnings.filterwarnings("ignore", message="PolymorphicModelBase._default_manager.*")

# TODO: - remove these lines, they are here only for testing that following error is the only stopper for upgrade to py3.12
warnings.filterwarnings("ignore", module="polymorphic") # monitor https://github.com/DefectDojo/django-DefectDojo/pull/10334, specially https://github.com/pypi/support/issues/4164
warnings.filterwarnings("ignore", module="github") # monitor https://github.com/DefectDojo/django-DefectDojo/pull/9948 but it might pop-up somewhere else again. pygithub is just first known location.

# The setting is here to avoid RemovedInDjango60Warning. It is here only for transition period.
# TODO: - Remove this setting in Django 6.0
Expand Down
Loading