generated from alecodes/base-template
chore: add build workflow
This commit is contained in:
parent
6288969c4d
commit
c4a908a62b
4 changed files with 137 additions and 1 deletions
|
|
@ -1,12 +1,16 @@
|
|||
FROM ghcr.io/linuxcontainers/debian-slim:latest
|
||||
|
||||
COPY --from=ghcr.io/amacneil/dbmate /usr/local/bin/dbmate /usr/local/bin/dbmate
|
||||
COPY --from=ghcr.io/amacneil/dbmate:main /usr/local/bin/dbmate /usr/local/bin/dbmate
|
||||
COPY --from=lovasoa/sqlpage:main /usr/local/bin/sqlpage /usr/local/bin/sqlpage
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
ENV SQLPAGE_WEB_ROOT=/app
|
||||
ENV SQLPAGE_CONFIGURATION_DIRECTORY=/app/sqlpage
|
||||
ENV DB_DRIVER=
|
||||
ENV DB_USER=
|
||||
ENV DB_NAME=
|
||||
ENV DB_PASSWORD_FILE=
|
||||
|
||||
RUN addgroup --gid 1000 --system index_user && \
|
||||
adduser --uid 1000 --system --no-create-home --ingroup index_user index_user && \
|
||||
|
|
@ -15,7 +19,12 @@ RUN addgroup --gid 1000 --system index_user && \
|
|||
chown -R index_user:index_user /etc/sqlpage/sqlpage.db
|
||||
|
||||
COPY --chown=index_user:index_user ./src /app
|
||||
COPY --chown=index_user:index_user ./docker/entrypoint.sh /usr/bin/entrypoint.sh
|
||||
|
||||
RUN chmod a+x /usr/bin/entrypoint.sh
|
||||
|
||||
USER index_user
|
||||
|
||||
ENTRYPOINT ["/usr/bin/entrypoint.sh"]
|
||||
|
||||
CMD /usr/local/bin/sqlpage
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue