Rather than require a heavy chown operation across various paths, just chown the files already in the built image during the release process. This ensures we can skip not-only the chown process during the container start that herokuish injects, but also the one that Dokku runs which modifies mounted container paths as well during the pre-deploy. Note that users will need to ensure any mounted volumes don't have permissions reset by other processes or containers won't be able to access them.
9 lines
182 B
Docker
9 lines
182 B
Docker
ARG APP_IMAGE
|
|
FROM $APP_IMAGE
|
|
|
|
ARG DOKKU_APP_USER herokuishuser
|
|
RUN USER=$DOKKU_APP_USER /exec true
|
|
COPY --chown=$DOKKU_APP_USER . /app
|
|
WORKDIR /app
|
|
ENV HEROKUISH_DISABLE_CHOWN true
|