From a2f174f6ed291d5b5017ccfa4307e6868c86ebef Mon Sep 17 00:00:00 2001 From: martinjrobins Date: Wed, 1 Mar 2023 13:46:27 +0000 Subject: [PATCH] #47 frontend-dev runs yarn install on docker-compose up --- docker-compose.dev.yml | 7 ++++++- docker-compose.yml | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index cf3bc90d..b1b81105 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -22,7 +22,12 @@ services: context: ./frontend ports: - "3000:3000" - command: yarn start + command: > + bash -c " + yarn install && + yarn start + " + restart: unless-stopped # old_worker: diff --git a/docker-compose.yml b/docker-compose.yml index 80525fbc..5cfde037 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -29,7 +29,6 @@ services: - "80:80" volumes: - ./frontend:/app - - /app/node_modules/ working_dir: /app env_file: - ./.env