diff --git a/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/Dockerfile.azure b/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/Dockerfile.azure new file mode 100644 index 0000000000..4586d6dc02 --- /dev/null +++ b/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/Dockerfile.azure @@ -0,0 +1,22 @@ +FROM node:16 AS nodebase + +FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build + +COPY --from=nodebase /usr/local/bin /usr/local/bin +COPY --from=nodebase /usr/local/lib /usr/local/lib + +WORKDIR /app +COPY . . + +RUN dotnet tool update --global Volo.Abp.Cli +ENV PATH="${PATH}:/root/.dotnet/tools/" +WORKDIR /app/abp/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo +RUN abp install-libs +RUN dotnet publish -c Release -o bin/Release/publish + +FROM mcr.microsoft.com/dotnet/aspnet:8.0 +WORKDIR /app +EXPOSE 80 +ENV ASPNETCORE_URLS=http://+:80 +COPY --from=build /app/abp/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/bin/Release/publish . +ENTRYPOINT ["dotnet", "Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo.dll"] diff --git a/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/azure-pipelines.yml b/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/azure-pipelines.yml index 7ace2e891a..235ef306de 100644 --- a/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/azure-pipelines.yml +++ b/modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/azure-pipelines.yml @@ -21,7 +21,7 @@ variables: DOCKER_BUILDKIT: 1 pool: - vmImage: 'ubuntu-latest' + name: aks-deployer-agent stages: @@ -31,21 +31,21 @@ stages: - job: Build displayName: Package Helm Charts and Values pool: - vmImage: 'ubuntu-latest' + name: aks-deployer-agent steps: - checkout: self - checkout: devops - - script: | - cd $(bootstrapTaghelpersDir) && dotnet publish -c Release -o bin/Release/publish + # - script: | + # cd $(bootstrapTaghelpersDir) && dotnet publish -c Release -o bin/Release/publish - task: Docker@2 displayName: Build Image inputs: command: build repository: demo/bootstrap-taghelpers - dockerfile: $(bootstrapTaghelpersDir)/Dockerfile - buildContext: $(bootstrapTaghelpersDir) + dockerfile: $(bootstrapTaghelpersDir)/Dockerfile.azure + buildContext: $(workDir) containerRegistry: $(dockerRegistryServiceConnection) tags: | $(tag)