Skip to content

Update Dockerfiles to Ubuntu 22.04 #4113

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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 tensorflow_serving/tools/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ ARG TF_SERVING_VERSION=latest
ARG TF_SERVING_BUILD_IMAGE=tensorflow/serving:${TF_SERVING_VERSION}-devel

FROM ${TF_SERVING_BUILD_IMAGE} as build_image
FROM ubuntu:20.04
FROM ubuntu:22.04

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=head
Expand Down
2 changes: 1 addition & 1 deletion tensorflow_serving/tools/docker/Dockerfile.devel
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
Copy link

@floringavrila floringavrila Jul 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did you tried to build this docker file ?
you could use python version 3.10 which comes installed on ubuntu 22

I do not think python 3.9 is available on ppa:deadsnakes/ppa. for ubuntu 22 ...

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't and I see there are some issues with the build. I'll try to figure that out

# limitations under the License.
FROM ubuntu:20.04 as base_build
FROM ubuntu:22.04 as base_build

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=HEAD
Expand Down
2 changes: 1 addition & 1 deletion tensorflow_serving/tools/docker/Dockerfile.devel-gpu
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
FROM nvidia/cuda:12.2.0-base-ubuntu20.04 as base_build
FROM nvidia/cuda:12.2.0-base-ubuntu22.04 as base_build

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=HEAD
Expand Down
2 changes: 1 addition & 1 deletion tensorflow_serving/tools/docker/Dockerfile.devel-mkl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
FROM ubuntu:20.04 as base_build
FROM ubuntu:22.04 as base_build

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=HEAD
Expand Down
2 changes: 1 addition & 1 deletion tensorflow_serving/tools/docker/Dockerfile.gpu
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ ARG TF_SERVING_VERSION=latest
ARG TF_SERVING_BUILD_IMAGE=tensorflow/serving:${TF_SERVING_VERSION}-devel-gpu

FROM ${TF_SERVING_BUILD_IMAGE} as build_image
FROM nvidia/cuda:12.2.0-base-ubuntu20.04 as base_build
FROM nvidia/cuda:12.2.0-base-ubuntu22.04 as base_build

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=HEAD
Expand Down
2 changes: 1 addition & 1 deletion tensorflow_serving/tools/docker/Dockerfile.mkl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ ARG TF_SERVING_VERSION=latest
ARG TF_SERVING_BUILD_IMAGE=tensorflow/serving:${TF_SERVING_VERSION}-devel-mkl

FROM ${TF_SERVING_BUILD_IMAGE} as build_image
FROM ubuntu:20.04
FROM ubuntu:22.04

ARG TF_SERVING_VERSION_GIT_BRANCH=master
ARG TF_SERVING_VERSION_GIT_COMMIT=head
Expand Down
8 changes: 4 additions & 4 deletions tensorflow_serving/tools/docker/setup.sources.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ cat >/etc/apt/sources.list.d/custom.list <<SOURCES
deb https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64 /

# More Python versions: Deadsnakes
deb http://ppa.launchpad.net/deadsnakes/ppa/ubuntu focal main
deb-src http://ppa.launchpad.net/deadsnakes/ppa/ubuntu focal main
deb http://ppa.launchpad.net/deadsnakes/ppa/ubuntu jammy main
deb-src http://ppa.launchpad.net/deadsnakes/ppa/ubuntu jammy main

# LLVM/Clang repository
deb http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main
deb-src http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main
deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
deb-src http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
SOURCES

apt-get update