fix(docs): isolate widget styles and add docker preview
This commit is contained in:
4 files changed
+44
-1
No files matched your search
@@ -26,4 +26,14 @@ Run the disposable service integration test from the repository root:
|
||||
pnpm test:workshop
|
||||
```
|
||||
|
||||
## Production docs preview
|
||||
|
||||
Build the documentation and serve it from PocketBase using the same production image layout as the hosted Workshop:
|
||||
|
||||
```sh
|
||||
pnpm docker:docs
|
||||
```
|
||||
|
||||
Open `http://127.0.0.1:3003`. Set `DOCS_EXPOSE_PORT` to use another host port. The preview container is removed when it stops and does not persist PocketBase data.
|
||||
|
||||
Production data lives in `/pb_data`. The image serves the built Homarr documentation and Workshop UI from `/pb_public`.
|
||||
Executable
+18
@@ -0,0 +1,18 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
DOCS_IMAGE=${DOCS_IMAGE:-homarr/docs:local}
|
||||
DOCS_EXPOSE_PORT=${DOCS_EXPOSE_PORT:-3003}
|
||||
|
||||
docker build \
|
||||
--target production \
|
||||
--file apps/workshop/Dockerfile \
|
||||
--tag "$DOCS_IMAGE" \
|
||||
.
|
||||
|
||||
exec docker run \
|
||||
--rm \
|
||||
--name homarr-docs \
|
||||
--publish "127.0.0.1:${DOCS_EXPOSE_PORT}:8090" \
|
||||
--env PB_ALLOWED_ORIGINS='*' \
|
||||
"$DOCS_IMAGE"
|
||||
Reference in new issue
Block a user