Add Set up Docker development environment in README.md (#997)

This commit is contained in:
Googol Lee
2024-07-23 21:56:30 +02:00
committed by GitHub
parent 0345bc1481
commit bdae9a67ce
5 changed files with 101 additions and 7 deletions

View File

@@ -60,8 +60,19 @@ RUN chmod +x /app/scripts/*.sh \
# Build api source
&& go build -v -o photoview .
### Copy api and ui to production environment ###
FROM --platform=${BUILDPLATFORM:-linux/amd64} debian:bookworm-slim AS final
### Build dev image for UI ###
FROM ui AS dev-ui
### Build dev image for API ###
FROM api AS dev-api
RUN source /app/scripts/set_compiler_env.sh \
&& /app/scripts/install_runtime_dependencies.sh \
## Install dev tools
&& apt update \
&& apt install -y reflex sqlite3
### Build release image ###
FROM --platform=${BUILDPLATFORM:-linux/amd64} debian:bookworm-slim AS release
ARG TARGETPLATFORM
# See for details: https://github.com/hadolint/hadolint/wiki/DL4006