From b66efbb5428ed1c70eb8358ddab351469386a669 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Gurhem?= Date: Wed, 6 Mar 2024 09:08:47 +0100 Subject: [PATCH] fix: do not create /cache and /local_storage in polling agent --- Dockerfile | 9 +-------- terraform/modules/compute_plane/main.tf | 2 +- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 04e5a59de..b4dfed7c7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,8 +4,6 @@ FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build ARG VERSION=1.0.0.0 ARG TARGETARCH -RUN mkdir /cache /local_storage - WORKDIR /src # git ls-tree -r HEAD --name-only --full-tree | grep "csproj$" | xargs -I % sh -c "export D=\$(dirname %) ; echo COPY [\\\"%\\\", \\\"\$D/\\\"]" COPY ["Adaptors/Amqp/src/ArmoniK.Core.Adapters.Amqp.csproj", "Adaptors/Amqp/src/"] @@ -73,9 +71,6 @@ WORKDIR /src/Control/Submitter/src RUN dotnet publish "ArmoniK.Core.Control.Submitter.csproj" -a $TARGETARCH --no-restore -o /app/publish/submitter /p:UseAppHost=false -p:RunAnalyzers=false -p:WarningLevel=0 -p:PackageVersion=$VERSION -p:Version=$VERSION FROM base as polling_agent -WORKDIR / -COPY --from=build --chown=$APP_UID:$APP_UID /cache /cache -COPY --from=build --chown=$APP_UID:$APP_UID /local_storage /local_storage WORKDIR /adapters/queue/pubsub COPY --from=build /app/publish/pubsub . WORKDIR /adapters/queue/amqp @@ -115,8 +110,6 @@ ENTRYPOINT ["dotnet", "ArmoniK.Core.Control.PartitionMetrics.dll"] FROM base as submitter -WORKDIR / -COPY --from=build --chown=$APP_UID:$APP_UID /local_storage /local_storage WORKDIR /adapters/queue/pubsub COPY --from=build /app/publish/pubsub . WORKDIR /adapters/queue/amqp @@ -131,4 +124,4 @@ ENV ASPNETCORE_URLS http://+:1080, http://+:1081 EXPOSE 1080 EXPOSE 1081 -ENTRYPOINT ["dotnet", "ArmoniK.Core.Control.Submitter.dll"] \ No newline at end of file +ENTRYPOINT ["dotnet", "ArmoniK.Core.Control.Submitter.dll"] diff --git a/terraform/modules/compute_plane/main.tf b/terraform/modules/compute_plane/main.tf index 9132a58c2..c046bf247 100644 --- a/terraform/modules/compute_plane/main.tf +++ b/terraform/modules/compute_plane/main.tf @@ -1,7 +1,7 @@ resource "docker_volume" "socket_vol" { name = "socket_vol${var.replica_counter}" driver_opts = { - o : "uid=3333" + o : "uid=3333,gid=3333,mode=0777" device : "tmpfs" type : "tmpfs" }