-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathContainerfile-web
More file actions
32 lines (20 loc) · 793 Bytes
/
Containerfile-web
File metadata and controls
32 lines (20 loc) · 793 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
FROM mcr.microsoft.com/dotnet/sdk:8.0 as build
RUN apt update && apt install -y nodejs python3
WORKDIR /usr/src/anna
COPY . .
# TODO: set api url
RUN wget -qO- https://get.pnpm.io/install.sh | ENV="$HOME/.bashrc" SHELL="$(which bash)" bash -
ENV PNPM_HOME=/root/.local/share/pnpm
ENV PATH=$PATH:$PNPM_HOME
RUN dotnet tool restore
RUN dotnet restore
RUN dotnet workload install wasm-tools
RUN dotnet publish --no-restore --configuration Release Anna.Web
FROM debian:bookworm
RUN apt update && apt install -y caddy python3
COPY --from=build /usr/src/anna/Anna.Web/bin/Release/net8.0/publish .
COPY Caddyfile .
COPY container-entrypoint-web.sh container-entrypoint.sh
COPY scripts/set_api_url.py .
ENV BLAZOR_ENVIRONMENT=Production
ENTRYPOINT ["/bin/bash", "container-entrypoint.sh"]