-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
5 changed files
with
75 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
.pnpm-debug.log* | ||
|
||
node_modules/ | ||
|
||
# Runtime data | ||
pids | ||
*.pid | ||
*.seed | ||
*.pid.lock | ||
|
||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
lib-cov | ||
|
||
# Coverage directory used by tools like istanbul | ||
coverage | ||
|
||
# Compiled binary addons (https://nodejs.org/api/addons.html) | ||
dist/ | ||
artifacts/ | ||
work/ | ||
ci/ | ||
e2e-results/ | ||
**/cypress/videos | ||
**/cypress/report.json | ||
|
||
# Editor | ||
.idea | ||
|
||
.eslintcache | ||
.codecc | ||
.vscode | ||
|
||
pre-*-bkcodeai |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
ARG NODE_IMAGE=node:20.11.1-slim | ||
ARG PNPM_VERSION=8 | ||
ARG NODE_PLATFORM=linux/amd64 | ||
|
||
FROM --platform=${NODE_PLATFORM} ${NODE_IMAGE} as nodejs | ||
|
||
WORKDIR /code | ||
|
||
RUN npm i -g pnpm@${PNPM_VERSION} | ||
|
||
COPY . . | ||
|
||
RUN pnpm i | ||
RUN pnpm run build | ||
RUN tar -czvf frontend.tar.gz src/alert/dist src/event/dist src/timeseries/dist | ||
|
||
CMD [ "echo", "前端构建完毕" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/bin/bash -e | ||
|
||
# 默认为./build | ||
target=${1:-./build} | ||
|
||
rm -rf ./build | ||
|
||
docker build -t bkmonitor_plugin_build . | ||
|
||
docker run -d --name plugin-temp-container bkmonitor_plugin_build | ||
|
||
mkdir -p "$target" | ||
|
||
docker cp plugin-temp-container:/code/frontend.tar.gz "$target" | ||
|
||
docker rm plugin-temp-container | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters