Compare commits

...

10 Commits

Author SHA1 Message Date
ra_ma
eb3bac9ff5 bump go version 2025-11-17 19:34:09 +00:00
ra_ma
6db73c926f drivers 2025-09-25 23:23:43 +01:00
1abb370706 Update Dockerfile
add jellyfin-ffmpeg
2025-09-24 19:01:59 +01:00
ra_ma
958bd63caf working build 2025-09-20 15:59:45 +01:00
ra_ma
0de342189a node build fixed 2025-09-20 14:11:14 +01:00
ra_ma
f254bae251 node build fixed 2025-09-20 14:09:56 +01:00
ra_ma
3d298fa434 node build fixed 2025-09-20 14:08:38 +01:00
ra_ma
c6ebbe069d mistral tempt 2025-09-20 13:41:28 +01:00
ra_ma
8e531fc054 fix build 2025-09-20 13:34:16 +01:00
ra_ma
a273dfeee5 fix download 2025-09-20 13:26:06 +01:00
2 changed files with 60 additions and 20 deletions

5
.gitignore vendored
View File

@@ -163,3 +163,8 @@ go.work.sum
# env file # env file
.env .env
# Project Specific
seanime-*/
tag.file
v*.tar.gz
DATA/

View File

@@ -1,31 +1,66 @@
ARG VERSION=latest ARG VERSION=latest
# Prep Files
FROM alpine:latest as downloader FROM alpine:latest as downloader
WORKDIR /src WORKDIR /src
RUN apk add --no-cache curl tar
# Download latest release info and extract the version tag
RUN curl -s https://api.github.com/repos/5rahim/seanime/releases/${VERSION} \
| grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/' > /src/tag.txt
RUN TAG=$(cat /src/tag.txt) && \
curl -L https://github.com/5rahim/seanime/archive/refs/tags/${TAG}.tar.gz -o seanime.tar.gz && \
tar -xzvf seanime.tar.gz
# Install dependencies
RUN apk add --no-cache curl tar wget
# Fetch the latest tag and download the source code
RUN curl -s https://api.github.com/repos/5rahim/seanime/releases/latest | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/' > tag.file && \
TAG=$(cat tag.file) && \
wget https://github.com/5rahim/seanime/archive/refs/tags/${TAG}.tar.gz && \
tar -xzvf ${TAG}.tar.gz && \
rm ${TAG}.tar.gz tag.file && \
mv seanime-* seanime
# Start web build
FROM node:18-alpine AS frontend-build FROM node:18-alpine AS frontend-build
WORKDIR /app/seanime-web
COPY --from=downloader /src/seanime*/seanime-web ./
RUN npm install
RUN npm run build
RUN mkdir -p /app/web && cp -r out/* /app/web/
FROM golang:1.23-alpine AS backend-build # Set working directory to the extracted source code
WORKDIR /app WORKDIR /app/seanime-web
COPY --from=downloader /src/seanime* ./
COPY --from=frontend-build /app/web ./web # Copy source from downloader
COPY --from=downloader /src/seanime/seanime-web ./
# Build the web interface
RUN npm install && \
npm run build && \
mkdir -p /app/web && \
cp -r out/* /app/web/
# Start backend build
FROM golang:1.25-alpine AS backend-build
# set build root
WORKDIR /build
# Copy needed files from previous stages
COPY --from=downloader /src/seanime /build
COPY --from=frontend-build /app/web /build/web
# Build the server for Linux
RUN go build -o seanime -trimpath -ldflags="-s -w" RUN go build -o seanime -trimpath -ldflags="-s -w"
# Complete the APP
FROM alpine:latest FROM alpine:latest
# Add FFMPEG to the final image
RUN apk add --no-cache jellyfin-ffmpeg mesa-dri-gallium mesa-va-gallium linux-firmware-amdgpu
# Set root
WORKDIR /app WORKDIR /app
COPY --from=backend-build /app/seanime .
COPY --from=backend-build /app/web ./web # Copy preped builds
COPY --from=backend-build /build/seanime .
# Set up the data directory
VOLUME /DATA
# Expose the port
EXPOSE 43211 EXPOSE 43211
VOLUME ["/DATA"]
CMD ["./seanime", "--datadir", "/DATA", "--port", "43211"] # Command to run the server
CMD ["/app/seanime", "--datadir", "/DATA"]