1 Commits
Author SHA1 Message Date
曾志威 eb52f4e7eb init
continuous-integration/drone Build is passing
2026-02-13 02:13:57 +08:00
3 changed files with 27 additions and 70 deletions
+22 -69
View File
@@ -1,77 +1,30 @@
kind: pipeline
name: default
clone:
disable: true
steps:
- name: clone-cbt-ui
image: docker.freeicu.top/alpine/git:latest
# 步骤2:拉取其他 Git 项目(common-utils)
- name: clone-other-project
image: alpine/git:latest # 轻量 Git 镜像
commands:
- >
git clone
-b proj-shopee-test
--depth 1
--no-tags
https://zwzeng:glpat-nuzkafsdgYKM0KAgvpL4Bm86MQp1OnkH.01.0w0tr4xa1@git.ittx.com.cn/cybertrans/frontend/cbt-ui.git
# 拉取其他项目到指定目录
- >
git clone
-b proj-snd-ess-3.1
--depth 1
https://zwzeng:glpat-Ht2452yuDgM84iNzu32b@git.ittx.com.cn/edi/edi-wms.git
- name: build-cbt-ui
image: docker.freeicu.top/library/node:22-alpine
pull: if-not-exists
environment:
NPM_USERNAME:
from_secret: nexus_username
NPM_PASSWORD:
from_secret: nexus_password
CBT_BUILD_OUTPUT_DIR: dist/release
# docker 打包
- name: deploy
image: registry.cn-hangzhou.aliyuncs.com/loghub/wms-system-service:gradle8
commands:
- cd edi-wms
- >
test -w /cache ||
(echo "Cache directory /cache is not mounted or writable" && exit 1)
- cd cbt-ui
- >
sed -i
's#https://dl-cdn.alpinelinux.org/alpine#https://mirrors.aliyun.com/alpine#'
/etc/apk/repositories
- apk add --no-cache expect
- corepack enable
- |
node <<'NODE'
const fs = require('fs')
const workspacePath = 'pnpm-workspace.yaml'
const workspace = fs.readFileSync(workspacePath, 'utf8')
const updated = workspace.replace(
/: set this to true or false$/gm,
': true',
)
if (updated === workspace) {
throw new Error('pnpm-workspace.yaml has no allowBuilds placeholders')
}
fs.writeFileSync(workspacePath, updated)
NODE
- pnpm config set store-dir /cache/cbt-ui/pnpm-store
- sh install.sh
- pnpm build:wes
- test -f dist/release/index.html
- >
sed -i
's#registry-vpc.cn-hangzhou.aliyuncs.com#registry.cn-hangzhou.aliyuncs.com#'
Dockerfile
- name: package-cbt-ui
image: docker.freeicu.top/plugins/docker:latest
settings:
context: ./cbt-ui
dockerfile: ./cbt-ui/Dockerfile
registry: registry.cn-hangzhou.aliyuncs.com
repo: registry.cn-hangzhou.aliyuncs.com/loghub/wes
tags:
- shopee-ui-test-1
cache_from:
- registry.cn-hangzhou.aliyuncs.com/loghub/wes:shopee-ui-test-1
username:
from_secret: docker_username
password:
from_secret: docker_password
purge: true
gradle jib -stacktrace
--parallel
-Pmax-workers=16
-x test
-PdockerBuild=true
-Dcybertrans.idp.enabled=false
-Djib.from.image=registry.cn-hangzhou.aliyuncs.com/loghub/wms-system-service:snde-jdk
-Djib.to.image=registry.cn-hangzhou.aliyuncs.com/loghub/wms-system-service
-Djib.to.tags=proj-walle-snde-edi-ess
-1
View File
@@ -1 +0,0 @@
.idea/
+5
View File
@@ -0,0 +1,5 @@
FROM rabbitmq:4.2-management-alpine
RUN set -eux; \
apk update; \
apk upgrade ;