-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #122 from Salvoxia/fix/dockerBuildFails
Fix/docker build fails
- Loading branch information
Showing
2 changed files
with
52 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,10 +2,14 @@ FROM python:3.12-alpine | |
LABEL maintainer="Salvoxia <[email protected]>" | ||
|
||
COPY immich_auto_album.py requirements.txt docker/immich_auto_album.sh docker/setup_cron.sh /script/ | ||
|
||
RUN pip install --no-cache-dir -r /script/requirements.txt \ | ||
ARG TARGETPLATFORM | ||
# gcc and musl-dev are required for building requirements for regex python module | ||
RUN if [ "$TARGETPLATFORM" = "linux/arm/v7" ]; then apk add gcc musl-dev; fi \ | ||
&& pip install --no-cache-dir -r /script/requirements.txt \ | ||
&& chmod +x /script/setup_cron.sh /script/immich_auto_album.sh \ | ||
&& rm -rf /tmp/* /var/tmp/* /var/cache/apk/* /var/cache/distfiles/* | ||
&& rm -rf /tmp/* /var/tmp/* /var/cache/apk/* /var/cache/distfiles/* \ | ||
&& if [ "$TARGETPLATFORM" = "linux/arm/v7" ]; then apk del gcc musl-dev; fi | ||
|
||
ENV IS_DOCKER=1 | ||
WORKDIR /script | ||
CMD ["sh", "-c", "/script/setup_cron.sh && crond -f"] |