1
0
mirror of https://github.com/bitwarden/server.git synced 2025-05-25 13:24:50 -05:00

Update MsSqlMigratorUtility Docker file

This commit is contained in:
Vince Grassia 2023-11-15 11:46:40 -05:00
parent 0444e9351b
commit 36e8341bc4
No known key found for this signature in database
GPG Key ID: 9AD7505E8448CC08

View File

@ -1,6 +1,8 @@
FROM mcr.microsoft.com/dotnet/aspnet:6.0
###############################################
# Build stage #
###############################################
LABEL com.bitwarden.product="bitwarden"
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS bitwarden-build
# Copy csproj files as distinct layers
WORKDIR /source
@ -20,4 +22,15 @@ RUN dotnet publish -c release -o /app/MsSqlMigratorUtility --no-restore --no-sel
WORKDIR /app
###############################################
# App stage #
###############################################
FROM mcr.microsoft.com/dotnet/aspnet:6.0
LABEL com.bitwarden.product="bitwarden"
# Copy app from the build stage
WORKDIR /app
COPY --from=bitwarden-build /app/MsSqlMigratorUtility ./
ENTRYPOINT ["sh", "-c", "dotnet /app/MsSqlMigratorUtility.dll \"${MSSQL_CONN_STRING}\" -v ${@}", "--" ]