Update Dockerfiles and add Python 3.11
Working directories in both ElsaServer.Dockerfile and ElsaServerAndStudio.Dockerfile have been updated for better consistency. Additionally, Python 3.11 has been installed in the ElsaServer.Dockerfile, accompanied by relevant environment variables and symbolic links to improve interoperability.
This commit is contained in:
parent
3454ca0df5
commit
062158b4d2
|
|
@ -10,7 +10,7 @@ COPY *.props ./
|
|||
RUN dotnet restore "./src/bundles/Elsa.Server.Web/Elsa.Server.Web.csproj"
|
||||
|
||||
# build and publish (UseAppHost=false creates platform independent binaries).
|
||||
WORKDIR /source/src/bundles/Elsa.AllInOne.Web
|
||||
WORKDIR /source/src/bundles/Elsa.Server.Web
|
||||
RUN dotnet build "Elsa.Server.Web.csproj" -c Release -o /app/build
|
||||
RUN dotnet publish "Elsa.Server.Web.csproj" -c Release -o /app/publish /p:UseAppHost=false --no-restore -f net8.0
|
||||
|
||||
|
|
@ -19,6 +19,16 @@ FROM mcr.microsoft.com/dotnet/aspnet:8.0-bookworm-slim AS base
|
|||
WORKDIR /app
|
||||
COPY --from=build /app/publish ./
|
||||
|
||||
# Install Python 3.11
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
python3.11 \
|
||||
python3-pip && \
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
ln -s /usr/bin/python3.11 /usr/bin/python
|
||||
|
||||
# Set PYTHONNET_PYDLL environment variable
|
||||
ENV PYTHONNET_PYDLL /usr/bin/python3.11
|
||||
|
||||
EXPOSE 80/tcp
|
||||
EXPOSE 443/tcp
|
||||
ENTRYPOINT ["dotnet", "Elsa.Server.Web.dll"]
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ RUN dotnet restore "./src/bundles/ElsaStudioWebAssembly/ElsaStudioWebAssembly.cs
|
|||
RUN dotnet restore "./src/bundles/Elsa.ServerAndStudio.Web/Elsa.ServerAndStudio.Web.csproj"
|
||||
|
||||
# build and publish (UseAppHost=false creates platform independent binaries).
|
||||
WORKDIR /source/src/bundles/Elsa.AllInOne.Web
|
||||
WORKDIR /source/src/bundles/Elsa.ServerAndStudio.Web
|
||||
RUN dotnet build "Elsa.ServerAndStudio.Web.csproj" -c Release -o /app/build
|
||||
RUN dotnet publish "Elsa.ServerAndStudio.Web.csproj" -c Release -o /app/publish /p:UseAppHost=false --no-restore -f net8.0
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue