
* Fixed file pathing for automated docker builds * Added back in renaming the Kavita executable * Testing new method for copying wwwroot folder * Fixed file pathing * Fixed pathing to test * Potential fix for Docker file permissions Co-authored-by: Chris Plaatjes <chris.p@boxbrite.com> Co-authored-by: Boxbrite User <boxbrite@Rathalos.localdomain>
39 lines
962 B
Docker
39 lines
962 B
Docker
#This Dockerfile creates a build for all architectures
|
|
|
|
#Image that copies in the files and passes them to the main image
|
|
FROM ubuntu:focal AS copytask
|
|
|
|
ARG TARGETPLATFORM
|
|
|
|
#Move the output files to where they need to be
|
|
RUN mkdir /files
|
|
COPY _output/*.tar.gz /files/
|
|
COPY Kavita-webui/dist /files/wwwroot
|
|
COPY copy_runtime.sh /copy_runtime.sh
|
|
RUN /copy_runtime.sh
|
|
|
|
#Production image
|
|
FROM ubuntu:focal
|
|
|
|
COPY --from=copytask /Kavita /kavita
|
|
COPY --from=copytask /files/wwwroot /kavita/wwwroot
|
|
|
|
#Installs program dependencies
|
|
RUN apt-get update \
|
|
&& apt-get install -y libicu-dev libssl1.1 pwgen \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
#Creates the data directory
|
|
RUN mkdir /kavita/data
|
|
|
|
RUN cp /kavita/appsettings.Development.json /kavita/appsettings.json \
|
|
&& sed -i 's/Data source=kavita.db/Data source=data\/kavita.db/g' /kavita/appsettings.json
|
|
|
|
COPY entrypoint.sh /entrypoint.sh
|
|
|
|
EXPOSE 5000
|
|
|
|
WORKDIR /kavita
|
|
|
|
ENTRYPOINT ["/bin/bash"]
|
|
CMD ["/entrypoint.sh"]
|