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

Nvidia 18.04 support #15

Merged
merged 6 commits into from
Feb 2, 2019
Merged

Nvidia 18.04 support #15

merged 6 commits into from
Feb 2, 2019

Conversation

tfoote
Copy link
Collaborator

@tfoote tfoote commented Jan 10, 2019

This is changing the nvidia snippet to be conditioned on 16.04 vs 18.04.
Following behaviors from:

Currently it's conditioned on the host OS, however because the snippet is done in the image I think it would be better to have it conditioned on the image's OS.

I'd originally thought that it was coupled to the host OS as you need the same nvidia drivers as the host. And it worked for 16.04 host and an 18.04 image using the 16.04 injection. However when using the 18.04 host it broke in #14.

@ruffsl can you verify that this works for you? And we can figure out how the parameterization should be done?

@ruffsl
Copy link
Member

ruffsl commented Jan 12, 2019

I had to update my python docker module in the env environment, but other than that it seems to be working. I can't seem to kill/exit with crtl+c though.

@tfoote tfoote force-pushed the nvidia_18.04_support branch from a3fc443 to 726fa06 Compare January 31, 2019 04:39
@tfoote
Copy link
Collaborator Author

tfoote commented Jan 31, 2019

@ruffsl I rebased this on top of #24 could you validate it works for you on 18.04?

@ruffsl
Copy link
Member

ruffsl commented Jan 31, 2019

Awsome, its working rather slick with rviz2 on my nvidia laptop. However, do we still need the FROM nvidia to COPY the 10_nvidia.json if its >= 18.04? Kind of a bummer I wait to download ~2.47GB on my home network for 107 bytes of json. @flx42 does this file change often? Is there tracked URL we should fetch it?
Perhaps https://gitlab.com/nvidia/opengl/raw/ubuntu<distro# e.g. 18.04>/glvnd/runtime/10_nvidia.json?inline=false

# Preamble from extension [nvidia]
# Ubuntu 16.04 with nvidia-docker2 beta opengl support
FROM nvidia/opengl:1.0-glvnd-devel-ubuntu18.04 as glvnd

FROM osrf/ros:crystal-desktop
# Snippet from extension [nvidia]
RUN apt-get update && apt-get install -y --no-install-recommends \
    libglvnd0\
	libgl1 \
	libglx0 \
	libegl1 \
	libgles2 \
    && rm -rf /var/lib/apt/lists/*
COPY --from=glvnd /usr/share/glvnd/egl_vendor.d/10_nvidia.json /usr/share/glvnd/egl_vendor.d/10_nvidia.json

ENV NVIDIA_VISIBLE_DEVICES ${NVIDIA_VISIBLE_DEVICES:-all}
ENV NVIDIA_DRIVER_CAPABILITIES ${NVIDIA_DRIVER_CAPABILITIES:+$NVIDIA_DRIVER_CAPABILITIES,}graphics

@tfoote tfoote force-pushed the nvidia_18.04_support branch from a1e1da1 to 9aadf6c Compare February 1, 2019 23:32
@tfoote tfoote merged commit 0195c8a into master Feb 2, 2019
@tfoote tfoote deleted the nvidia_18.04_support branch February 2, 2019 01:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants