From fe859a075cafd3e91849c9ebbbc56cdd7a5c148e Mon Sep 17 00:00:00 2001 From: Iain Sproat <68657+iainsproat@users.noreply.github.com> Date: Fri, 11 Apr 2025 16:06:58 +0100 Subject: [PATCH] chore(preview-service): update README (#4389) * chore(preview-service): update README * Update README for docker --- packages/preview-service/readme.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/packages/preview-service/readme.md b/packages/preview-service/readme.md index eec2ed889..91ca91e16 100644 --- a/packages/preview-service/readme.md +++ b/packages/preview-service/readme.md @@ -30,7 +30,17 @@ Then build the service: yarn build ``` -This builds both typescript and webpack (for the page that is deployed to chromium to create the views). It should be rerun whenever you make changes to the viewer (if you make local viewer changes, don't forget to build the viewer module before running this) +We also need to build the preview-service frontend: + +```bash +yarn build:frontend +``` + +Then, we need to copy the built artefacts from the preview-service frontend in to the preview-service (backend) directory: + +```bash +yarn link:frontend +``` Finally, you can run the preview service with: @@ -51,7 +61,7 @@ docker build -f packages/preview-service/Dockerfile -t speckle-preview-service:l Once you have built the preview service Dockerfile, you can run it like so: ```bash -docker run --rm -p 3001:3001 -e PORT=3001 -e PG_CONNECTION_STRING=postgres://speckle:speckle@host.docker.internal/speckle speckle-preview-service:local +docker run --rm -p 3001:3001 -e PORT=3001 -e REDIS_URL=redis://redis:6379 speckle-preview-service:local ``` ## Deployment notes