Skip to content

Commit

Permalink
Merge pull request #108 from Arquisoft/build_sergiollende
Browse files Browse the repository at this point in the history
Changes to dockerfile and docker-compose - Deployment working
  • Loading branch information
UO289930 authored Mar 13, 2024
2 parents 84f26ae + 9aa364d commit aaddb0b
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 18 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
wikidata_service:
container_name: wikidata_service-${teamname:-defaultASW}
image: ghcr.io/arquisoft/wiq_en3a/wikidata_service:latest
build: ./wikidata_service/WikiDataTest
build: ./wikidata_service
profiles: ["dev", "prod"]
ports:
- "7259:7259"
Expand Down
22 changes: 22 additions & 0 deletions wikidata_service/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
FROM mcr.microsoft.com/dotnet/aspnet:6.0 AS base
WORKDIR /app
EXPOSE 80
EXPOSE 443

FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
ARG BUILD_CONFIGURATION=Release
WORKDIR /src
COPY ["WikiDataTest/WikiDataTest.csproj", "WikiDataTest/"]
RUN dotnet restore "./WikiDataTest/./WikiDataTest.csproj"
COPY . .
WORKDIR "/src/WikiDataTest"
RUN dotnet build "./WikiDataTest.csproj" -c %BUILD_CONFIGURATION% -o /app/build

FROM build AS publish
ARG BUILD_CONFIGURATION=Release
RUN dotnet publish "./WikiDataTest.csproj" -c %BUILD_CONFIGURATION% -o /app/publish /p:UseAppHost=false

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "WikiDataTest.dll"]
17 changes: 0 additions & 17 deletions wikidata_service/WikiDataTest/Dockerfile

This file was deleted.

0 comments on commit aaddb0b

Please sign in to comment.