mirror of
https://github.com/Novaloop-AG/healthchat-web.git
synced 2026-10-31 08:15:07 +00:00
ci: add element-plugin build to Docker pipeline
This commit is contained in:
@@ -25,6 +25,29 @@ jobs:
|
|||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0 # needed for docker-package to be able to calculate the version
|
fetch-depth: 0 # needed for docker-package to be able to calculate the version
|
||||||
|
- name: Checkout healthchat-workspace
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
repository: Novaloop-AG/healthchat-workspace
|
||||||
|
path: healthchat-workspace
|
||||||
|
token: ${{ secrets.HEALTHCHAT_WORKSPACE_TOKEN }}
|
||||||
|
- name: Setup Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 22
|
||||||
|
- name: Build element-plugin
|
||||||
|
run: |
|
||||||
|
cd healthchat-workspace/element-plugin
|
||||||
|
npm ci
|
||||||
|
npm run build
|
||||||
|
cd module
|
||||||
|
npm ci
|
||||||
|
npm run build
|
||||||
|
- name: Stage plugin artifacts for Docker
|
||||||
|
run: |
|
||||||
|
mkdir -p plugin-dist/elements
|
||||||
|
cp healthchat-workspace/element-plugin/module/dist/healthchat-module.js plugin-dist/healthchat-module.js
|
||||||
|
cp healthchat-workspace/element-plugin/dist/elements/browser/main.js plugin-dist/elements/healthchat-elements.js
|
||||||
- name: Log in to the Github Container registry
|
- name: Log in to the Github Container registry
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v3
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -42,3 +42,6 @@ storybook-static
|
|||||||
# vitepress
|
# vitepress
|
||||||
/docs/.vitepress/dist
|
/docs/.vitepress/dist
|
||||||
/docs/.vitepress/cache
|
/docs/.vitepress/cache
|
||||||
|
|
||||||
|
# HealthChat plugin build artifacts
|
||||||
|
/plugin-dist
|
||||||
|
|||||||
@@ -21,6 +21,11 @@ RUN pnpm install --frozen-lockfile
|
|||||||
COPY --link --exclude=.git --exclude=apps/web/docker . /src
|
COPY --link --exclude=.git --exclude=apps/web/docker . /src
|
||||||
RUN --mount=type=bind,source=.git,target=/src/.git /src/scripts/docker-package.sh
|
RUN --mount=type=bind,source=.git,target=/src/.git /src/scripts/docker-package.sh
|
||||||
|
|
||||||
|
# Copy HealthChat plugin artifacts
|
||||||
|
RUN mkdir -p /src/apps/web/webapp/modules/elements
|
||||||
|
COPY plugin-dist/healthchat-module.js /src/apps/web/webapp/modules/healthchat-module.js
|
||||||
|
COPY plugin-dist/elements/healthchat-elements.js /src/apps/web/webapp/modules/elements/healthchat-elements.js
|
||||||
|
|
||||||
# Copy the config now so that we don't create another layer in the app image
|
# Copy the config now so that we don't create another layer in the app image
|
||||||
RUN cp /src/apps/web/config.sample.json /src/apps/web/webapp/config.json
|
RUN cp /src/apps/web/config.sample.json /src/apps/web/webapp/config.json
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user