43 lines
1.4 KiB
Docker
43 lines
1.4 KiB
Docker
FROM jellyfin/jellyfin:latest as buildstage
|
||
|
||
RUN apt-get update -y && \
|
||
apt-get install -y build-essential libfuse-dev libcurl4-openssl-dev libxml2-dev pkg-config libssl-dev mime-support automake libtool wget tar git unzip
|
||
RUN apt-get install lsb-release -y && apt-get install zip -y && apt-get install vim -y
|
||
#RUN echo "deb http://deb.debian.org/debian/ bookworm main contrib non-free non-free-firmware" > /etc/apt/sources.list
|
||
#RUN apt-get update -y && apt install libnvcuvid1 libnvidia-encode1 -y
|
||
|
||
|
||
## Install S3 Fuse
|
||
RUN rm -rf /usr/src/s3fs-fuse
|
||
RUN git clone --branch v1.91 https://github.com/s3fs-fuse/s3fs-fuse/ /usr/src/s3fs-fuse
|
||
WORKDIR /usr/src/s3fs-fuse
|
||
RUN ./autogen.sh && ./configure && make && make install
|
||
|
||
## Create folder
|
||
WORKDIR /var/www
|
||
RUN mkdir s3
|
||
|
||
## Set Your AWS Access credentials
|
||
ARG AWS_ACCESS_KEY=$AWS_ACCESS_KEY
|
||
ENV AWS_ACCESS_KEY=$AWS_ACCESS_KEY
|
||
ARG AWS_SECRET_ACCESS_KEY=$AWS_ACCESS_KEY
|
||
ENV AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY
|
||
|
||
## Set the directory where you want to mount your s3 bucket
|
||
ARG S3_MOUNT_DIRECTORY=/var/www/s3
|
||
ENV S3_MOUNT_DIRECTORY=$S3_MOUNT_DIRECTORY
|
||
|
||
## Replace with your s3 bucket name
|
||
ARG S3_BUCKET_NAME=$S3_BUCKET_NAME
|
||
ENV S3_BUCKET_NAME=$S3_BUCKET_NAME
|
||
|
||
## Mount S3 bucket and create automatic mount script
|
||
|
||
COPY entrypoint.sh /entrypoint.sh
|
||
|
||
# ports and volumes
|
||
EXPOSE 8096 8920
|
||
RUN chmod 755 /config -R
|
||
RUN chmod 755 /entrypoint.sh
|
||
ENTRYPOINT ["/entrypoint.sh"]
|