From 3af49f593e62e5be85f773183d3a4d1054f25d66 Mon Sep 17 00:00:00 2001 From: nichlaes Date: Wed, 10 Jan 2024 15:23:34 +0100 Subject: [PATCH] adds ml-workspace and traefik --- client/dockerfile | 5 ++--- compose.yml | 50 +++++++++++++++++++++++------------------------ 2 files changed, 27 insertions(+), 28 deletions(-) diff --git a/client/dockerfile b/client/dockerfile index 67173f1bc..7adee703b 100644 --- a/client/dockerfile +++ b/client/dockerfile @@ -1,6 +1,5 @@ -FROM node:20.10.0-slim - #! docker should be run from the root directory of the project +FROM node:20.10.0-slim # Set the working directory inside the container WORKDIR /dtaas/client @@ -18,4 +17,4 @@ COPY ./client/ . RUN yarn build # Define the command to run your app -CMD ["yarn", "start"] +CMD ["yarn", "start"] \ No newline at end of file diff --git a/compose.yml b/compose.yml index 458ecdbdd..d761a4e05 100644 --- a/compose.yml +++ b/compose.yml @@ -8,7 +8,7 @@ services: ports: - "4000:4000" volumes: - - "$PWD/deploy/config/client/env.js:/dtaas/client/build/env.js" + - "$PWD/client/config/dev.js:/dtaas/client/build/env.js" libms: build: context: ./ @@ -18,7 +18,6 @@ services: volumes: - "$PWD/deploy/config/lib.docker:/dtaas/libms/.env" - "$PWD/files:/dtaas/libms/files" - runner: build: context: ./ @@ -28,27 +27,28 @@ services: volumes: - "$PWD/files:/dtaas/runner/files" - # ml-workspace-user1: - # image: mltooling/ml-workspace-minimal:0.13.2 - # container_name: ml-workspace-user1 - # ports: - # - "8090:8080" - # volumes: - # - "$PWD/files/user1:/workspace" - # - "$PWD/files/common:/workspace/common" - # environment: - # - AUTHENTICATE_VIA_JUPYTER="" - # - WORKSPACE_BASE_URL="user1" - # shm_size: 512m - # restart: always + ml-workspace-user1: + image: mltooling/ml-workspace-minimal:0.13.2 + container_name: ml-workspace-user1 + ports: + - "8090:8080" + volumes: + - "$PWD/files/user1:/workspace" + - "$PWD/files/common:/workspace/common" + environment: + - AUTHENTICATE_VIA_JUPYTER + - WORKSPACE_BASE_URL=user1 + shm_size: 512m + restart: always - # traefik-gateway: - # image: traefik:v2.10 - # container_name: traefik-gateway - # network_mode: host - # volumes: - # - "$PWD/servers/config/gateway/traefik.yml:/etc/traefik/traefik.yml" - # - "$PWD/servers/config/gateway/auth:/etc/traefik/auth" - # - "$PWD/servers/config/gateway/dynamic:/etc/traefik/dynamic" - # - "/var/run/docker.sock:/var/run/docker.sock" - # restart: always \ No newline at end of file + traefik-gateway: + image: traefik:v2.10 + container_name: traefik-gateway + ports: + - "9000:80" + volumes: + - "$PWD/servers/config/gateway/traefik.yml:/etc/traefik/traefik.yml" + - "$PWD/servers/config/gateway/auth:/etc/traefik/auth" + - "$PWD/servers/config/gateway/dynamic/fileConfig.docker.yml:/etc/traefik/dynamic/fileConfig.yml" + - "/var/run/docker.sock:/var/run/docker.sock" + restart: always \ No newline at end of file