mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-12-26 05:39:38 +00:00
Added Global Definition of PUID and GUID for ease of management only.
This commit is contained in:
parent
ce1540e781
commit
d9e7db2b5c
1 changed files with 10 additions and 6 deletions
16
Dockerfile
16
Dockerfile
|
|
@ -1,5 +1,9 @@
|
|||
# globally defining Arguments and Defaults
|
||||
ARG NUSQLITE3_DIR="/usr/local/lib/nusqlite3"
|
||||
ARG NUSQLITE3_PATH="${NUSQLITE3_DIR}/libnusqlite3.so"
|
||||
# default Process user id and group id
|
||||
ARG PUID=1000
|
||||
ARG PGID=1000
|
||||
|
||||
### STAGE 0: Build client ###
|
||||
FROM node:20-alpine AS build-client
|
||||
|
|
@ -45,8 +49,8 @@ FROM node:20-alpine
|
|||
|
||||
ARG NUSQLITE3_DIR
|
||||
ARG NUSQLITE3_PATH
|
||||
ARG PUID=1000
|
||||
ARG PGID=1000
|
||||
ARG PUID
|
||||
ARG PGID
|
||||
|
||||
# Install only runtime dependencies
|
||||
RUN apk add --no-cache --update \
|
||||
|
|
@ -59,14 +63,14 @@ RUN apk add --no-cache --update \
|
|||
&& apk del shadow \
|
||||
&& mkdir -p /config /metadata \
|
||||
&& chown -R audiobookshelf:audiobookshelf /config /metadata \
|
||||
&& chmod u=rwx,go=rw /config /metadata
|
||||
&& chmod a=rws /config /metadata
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy compiled frontend and server from build stages
|
||||
COPY --from=build-client /client/dist /app/client/dist
|
||||
COPY --from=build-server /server /app
|
||||
COPY --from=build-server ${NUSQLITE3_PATH} ${NUSQLITE3_PATH}
|
||||
COPY --chmod=755 --from=build-client /client/dist /app/client/dist
|
||||
COPY --chmod=755 --from=build-server /server /app
|
||||
COPY --chmod=755 --from=build-server ${NUSQLITE3_PATH} ${NUSQLITE3_PATH}
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue