Updated dockerfile
This commit is contained in:
@@ -78,14 +78,19 @@ ENV SETUPTOOLS_SCM_PRETEND_VERSION_FOR_BREWMAN=$SETUPTOOLS_SCM_PRETEND_VERSION_F
|
|||||||
RUN --mount=type=cache,target=/root/.cache/uv \
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
||||||
--mount=type=bind,source=brewman/uv.lock,target=uv.lock \
|
--mount=type=bind,source=brewman/uv.lock,target=uv.lock \
|
||||||
--mount=type=bind,source=brewman/pyproject.toml,target=pyproject.toml \
|
--mount=type=bind,source=brewman/pyproject.toml,target=pyproject.toml \
|
||||||
|
--mount=source=.git,target=.git,type=bind \
|
||||||
uv sync --locked --no-install-project
|
uv sync --locked --no-install-project
|
||||||
|
|
||||||
COPY /brewman ./
|
COPY /brewman ./
|
||||||
COPY --from=builder /frontend/browser /app/frontend
|
COPY --from=builder /frontend/browser /app/frontend
|
||||||
|
RUN ls -lah
|
||||||
|
|
||||||
# Sync the project
|
# Sync the project
|
||||||
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#intermediate-layers
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#intermediate-layers
|
||||||
RUN --mount=type=cache,target=/root/.cache/uv \
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
||||||
|
--mount=type=bind,source=brewman/uv.lock,target=uv.lock \
|
||||||
|
--mount=type=bind,source=brewman/pyproject.toml,target=pyproject.toml \
|
||||||
|
--mount=source=.git,target=.git,type=bind \
|
||||||
uv sync --locked --no-editable
|
uv sync --locked --no-editable
|
||||||
|
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ build-production: ## Build the production container image. Usage: make build-pro
|
|||||||
--manifest registry.tanshu.com/brewman:latest \
|
--manifest registry.tanshu.com/brewman:latest \
|
||||||
--pull \
|
--pull \
|
||||||
--build-arg SETUPTOOLS_SCM_PRETEND_VERSION_FOR_BREWMAN=$(TAG) \
|
--build-arg SETUPTOOLS_SCM_PRETEND_VERSION_FOR_BREWMAN=$(TAG) \
|
||||||
git@git.tanshu.com:tanshu/brewman.git#v$(TAG)
|
https://git.tanshu.com/tanshu/brewman.git#v$(TAG)
|
||||||
|
|
||||||
@echo "Pushing manifests..."
|
@echo "Pushing manifests..."
|
||||||
@podman manifest push --all registry.tanshu.com/brewman:latest docker://registry.tanshu.com/brewman:latest
|
@podman manifest push --all registry.tanshu.com/brewman:latest docker://registry.tanshu.com/brewman:latest
|
||||||
@@ -22,4 +22,4 @@ build-check: ## Multi-arch build without push (compile check). Usage: make build
|
|||||||
--manifest brewman:test \
|
--manifest brewman:test \
|
||||||
--pull \
|
--pull \
|
||||||
--build-arg SETUPTOOLS_SCM_PRETEND_VERSION_FOR_BREWMAN=$(TAG) \
|
--build-arg SETUPTOOLS_SCM_PRETEND_VERSION_FOR_BREWMAN=$(TAG) \
|
||||||
git@git.tanshu.com:tanshu/brewman.git#v$(TAG)
|
https://git.tanshu.com/tanshu/brewman.git#v$(TAG)
|
||||||
|
|||||||
Reference in New Issue
Block a user