chore: 初始开源发布

iotlcm-app:小程序端 + 用户端服务。

- app/:uni-app 小程序前端(基于 unibest,MIT)
  - 微信 AppID → YOUR_WX_APPID,uni-app AppID → __UNI__YOURAPPID
  - 内网后端地址 → admin.iotlcm.example.com
  - 应用标题与 unibest 模板 README 重写(保留上游致谢与 MIT 声明)
- server/:GoFrame 用户端服务(基于 XiuAdmin,Apache-2.0)
  - module xiuadmin → git.5iot.com/iotlcm-public/iotlcm-app(360 文件)
  - 支付回调地址 → app.iotlcm.example.com,商户名与应用名泛化
  - 真实手机号 → 合法 11 位编造号(保留号段前 3 位 + 后 4 位)
  - 依赖号码尾部的断言同步更新
  - 补 server/LICENSE(Apache-2.0)
- 移除内部资产:CI 触发器
- 补根 README,LF 行尾 + .gitattributes

已知:TestSysDept_RefreshDeptAncestors 在源仓同一提交上同样失败,属既有缺陷。
This commit is contained in:
MiFaZhan
2026-10-26 14:01:25 +08:00
commit 2ed5dfa6a1
1013 changed files with 138466 additions and 0 deletions
+129
View File
@@ -0,0 +1,129 @@
# Build context: app/
# Example:
# docker build -f Dockerfile -t iotlcm-app-web:latest .
FROM crpi-svwhn8x8nvask31h.cn-beijing.personal.cr.aliyuncs.com/xjzlpublic/node:24-alpine AS builder
WORKDIR /build/app
COPY package.json pnpm-lock.yaml .npmrc ./
RUN npm config set registry https://registry.npmmirror.com/ && \
npm install -g pnpm@10.10.0 --registry=https://registry.npmmirror.com/ && \
pnpm config set registry https://registry.npmmirror.com/ && \
pnpm install --frozen-lockfile --ignore-scripts
COPY index.html vite.config.ts manifest.config.ts pages.config.ts tsconfig.json ./
COPY uno.config.ts wot-ui-resolver.ts openapi-ts-request.config.ts ./
COPY folder-alias.json favicon.ico ./
COPY env ./env
COPY public ./public
COPY scripts ./scripts
COPY src ./src
COPY vite-plugins ./vite-plugins
ARG VITE_SERVER_BASEURL=/app/api/v1
ARG VITE_MP_SERVER_BASEURL=http://yznw2.xiujie.cn:8010/api/v1
ARG VITE_APP_PUBLIC_BASE=/app/
RUN printf '%s\n' \
"VITE_SERVER_BASEURL='${VITE_SERVER_BASEURL}'" \
"VITE_MP_SERVER_BASEURL='${VITE_MP_SERVER_BASEURL}'" \
"VITE_APP_PUBLIC_BASE='${VITE_APP_PUBLIC_BASE}'" \
> env/.env.production.local
RUN pnpm init-baseFiles
RUN CI=true pnpm build:h5:prod
FROM crpi-svwhn8x8nvask31h.cn-beijing.personal.cr.aliyuncs.com/xjzlpublic/nginx:1.30.0-alpine AS runtime
COPY --from=builder /build/app/dist/build/h5 /usr/share/nginx/html
RUN printf '%s\n' \
'server {' \
' listen 80;' \
' server_name _;' \
' root /usr/share/nginx/html;' \
' index index.html;' \
' resolver 127.0.0.11 ipv6=off valid=30s;' \
' set $app_backend http://iotlcm-app-server:8010;' \
'' \
' client_max_body_size 200m;' \
'' \
' location = /app {' \
' return 301 /app/;' \
' }' \
'' \
' location ^~ /app/api/ {' \
' rewrite ^/app/(.*)$ /$1 break;' \
' proxy_http_version 1.1;' \
' proxy_set_header Host $host;' \
' proxy_set_header X-Real-IP $remote_addr;' \
' proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;' \
' proxy_set_header X-Forwarded-Proto $scheme;' \
' proxy_pass $app_backend;' \
' }' \
'' \
' location ^~ /app/upload/ {' \
' rewrite ^/app/(.*)$ /$1 break;' \
' proxy_http_version 1.1;' \
' proxy_set_header Host $host;' \
' proxy_set_header X-Real-IP $remote_addr;' \
' proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;' \
' proxy_set_header X-Forwarded-Proto $scheme;' \
' proxy_pass $app_backend;' \
' }' \
'' \
' location ^~ /app/assets/ {' \
' rewrite ^/app/(.*)$ /$1 break;' \
' expires 30d;' \
' add_header Cache-Control "public, immutable";' \
' try_files $uri =404;' \
' }' \
'' \
' location ^~ /app/ {' \
' rewrite ^/app/(.*)$ /$1 break;' \
' try_files $uri $uri/ /index.html;' \
' }' \
'' \
' gzip on;' \
' gzip_types text/plain text/css application/json application/javascript application/xml image/svg+xml;' \
'' \
' location / {' \
' try_files $uri $uri/ /index.html;' \
' }' \
'' \
' location = /favicon.ico {' \
' alias /usr/share/nginx/html/static/images/shandong-yunze-logo.png;' \
' add_header Cache-Control "no-cache";' \
' }' \
'' \
' location /api/ {' \
' proxy_http_version 1.1;' \
' proxy_set_header Host $host;' \
' proxy_set_header X-Real-IP $remote_addr;' \
' proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;' \
' proxy_set_header X-Forwarded-Proto $scheme;' \
' proxy_pass $app_backend;' \
' }' \
'' \
' location /upload/ {' \
' proxy_http_version 1.1;' \
' proxy_set_header Host $host;' \
' proxy_set_header X-Real-IP $remote_addr;' \
' proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;' \
' proxy_set_header X-Forwarded-Proto $scheme;' \
' proxy_pass $app_backend;' \
' }' \
'' \
' location /assets/ {' \
' expires 30d;' \
' add_header Cache-Control "public, immutable";' \
' try_files $uri =404;' \
' }' \
'}' \
> /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]