mirror of
https://github.com/spritsail/plex-media-server.git
synced 2024-12-20 11:34:36 +00:00
Add nvidia libraries into :nvidia image
Pull the nvidia encoding and decoding libraries from Debian and include them in the image. This change is only a test and doesn't build the base Plex image first, which the CI pipeline should do when this is merged into pass. Fixes #34 Signed-off-by: Joe Groocock <me@frebib.net>
This commit is contained in:
parent
2d543fb511
commit
a2110c9ecc
35
.drone.yml
35
.drone.yml
@ -1,54 +1,39 @@
|
|||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
name: build-amd64
|
name: build-nvidia-amd64
|
||||||
|
|
||||||
platform:
|
platform:
|
||||||
os: linux
|
os: linux
|
||||||
arch: amd64
|
arch: amd64
|
||||||
|
|
||||||
|
#depends_on:
|
||||||
|
#- build-amd64
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: build
|
- name: build
|
||||||
pull: always
|
pull: always
|
||||||
image: spritsail/docker-build
|
image: spritsail/docker-build
|
||||||
settings:
|
settings:
|
||||||
|
dockerfile: Dockerfile.nvidia
|
||||||
make: true
|
make: true
|
||||||
|
|
||||||
- name: test-bin
|
|
||||||
pull: always
|
|
||||||
image: spritsail/docker-test
|
|
||||||
settings:
|
|
||||||
run: |
|
|
||||||
busybox && \
|
|
||||||
curl --version && \
|
|
||||||
xmlstarlet --version
|
|
||||||
|
|
||||||
- name: test
|
|
||||||
pull: always
|
|
||||||
image: spritsail/docker-test
|
|
||||||
settings:
|
|
||||||
curl: :32400/identity
|
|
||||||
delay: 5
|
|
||||||
pipe: |
|
|
||||||
xmlstarlet sel -t -v "/MediaContainer/@version" |
|
|
||||||
grep -qw "$(label io.spritsail.version.plex | cut -d- -f1)"
|
|
||||||
retry: 10
|
|
||||||
|
|
||||||
- name: publish
|
- name: publish
|
||||||
pull: always
|
pull: always
|
||||||
image: spritsail/docker-publish
|
image: spritsail/docker-publish
|
||||||
settings:
|
settings:
|
||||||
repo: spritsail/plex-media-server
|
repo: spritsail/plex-media-server
|
||||||
tags:
|
tags:
|
||||||
- plexpass
|
- plexpass-nvidia
|
||||||
- "%label io.spritsail.version.plex | %prefix plexpass | %remsuf [0-9a-f]+$ | %auto 2"
|
- "%label io.spritsail.version.plex | %prefix plexpass-nvidia | %remsuf [0-9a-f]+$ | %auto 2"
|
||||||
login: {from_secret: docker_login}
|
login: {from_secret: docker_login}
|
||||||
when:
|
when:
|
||||||
branch:
|
branch:
|
||||||
- pass
|
- nvidia
|
||||||
event:
|
event:
|
||||||
- push
|
- push
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: signature
|
kind: signature
|
||||||
hmac: a6e529b62ed2ecf24b2c3125f7267c321d56ce16d1cd8178f96e0399dd3096bd
|
hmac: d7799de75f1932b1aa3757273cad30c30d56442175e1ca2714720b252f6d7398
|
||||||
|
|
||||||
...
|
...
|
||||||
|
27
Dockerfile.nvidia
Normal file
27
Dockerfile.nvidia
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
ARG PLEX_VER=1.23.4.4712
|
||||||
|
ARG NVIDIA_VER=465.31
|
||||||
|
ARG NVIDIA_REV=1
|
||||||
|
ARG ARCH=amd64
|
||||||
|
|
||||||
|
FROM alpine
|
||||||
|
|
||||||
|
ARG NVIDIA_VER
|
||||||
|
ARG NVIDIA_REV
|
||||||
|
ARG ARCH
|
||||||
|
|
||||||
|
RUN apk add --no-cache curl dpkg && \
|
||||||
|
for pkg in libnvcuvid1 libnvidia-encode1; do \
|
||||||
|
curl -fsSLO https://deb.debian.org/debian/pool/non-free/n/nvidia-graphics-drivers/${pkg}_${NVIDIA_VER}-${NVIDIA_REV}_${ARCH}.deb && \
|
||||||
|
dpkg-deb -x ${pkg}_${NVIDIA_VER}-${NVIDIA_REV}_${ARCH}.deb /nvidia; \
|
||||||
|
done
|
||||||
|
|
||||||
|
# ~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
FROM spritsail/plex-media-server:plexpass-${PLEX_VER}
|
||||||
|
|
||||||
|
ARG NVIDIA_VER
|
||||||
|
|
||||||
|
COPY --from=0 \
|
||||||
|
/nvidia/usr/lib/x86_64-linux-gnu/nvidia/current/libnvcuvid.so.${NVIDIA_VER} \
|
||||||
|
/nvidia/usr/lib/x86_64-linux-gnu/nvidia/current/libnvidia-encode.so.${NVIDIA_VER} \
|
||||||
|
/usr/lib/
|
Loading…
Reference in New Issue
Block a user