Merge pull request '重构了项目目录结构,并初步整理了文档结构' (#1) from mengning into main
Reviewed-on: devstar/docs#1
25
.devcontainer/devcontainer.json
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"name": "dev-vitepress",
|
||||
"image": "node:20-alpine",
|
||||
|
||||
"customizations": {
|
||||
"vscode": {
|
||||
"settings": {},
|
||||
"extensions": [
|
||||
"vue.volar",
|
||||
"vue.vscode-typescript-vue-plugin",
|
||||
"bradlc.vscode-tailwindcss",
|
||||
"esbenp.prettier-vscode"
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
"portsAttributes": {
|
||||
"5173": {
|
||||
"label": "vitepress debug",
|
||||
"onAutoForward": "notify"
|
||||
}
|
||||
},
|
||||
"postCreateCommand": "apk add git && npm install && npm add -D vitepress",
|
||||
"postAttachCommand": "npm run dev"
|
||||
}
|
||||
@@ -28,7 +28,7 @@ jobs:
|
||||
working-directory:
|
||||
run: |
|
||||
chmod +x node_modules/.bin/vitepress
|
||||
npm run docs:build
|
||||
npm run build
|
||||
|
||||
- name: 构建 Docker 镜像
|
||||
run: |
|
||||
|
||||
6
.gitignore
vendored
@@ -1,7 +1,7 @@
|
||||
# VitePress
|
||||
docs/.vitepress/dist/
|
||||
docs/.vitepress/cache/
|
||||
docs/.vitepress/.temp/
|
||||
.vitepress/dist/
|
||||
.vitepress/cache/
|
||||
.vitepress/.temp/
|
||||
|
||||
# Node.js
|
||||
node_modules/
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import { defineConfig } from 'vitepress'
|
||||
import type { DefaultTheme } from 'vitepress'
|
||||
import { set_sidebar } from "../utils/auto_sidebar.js";
|
||||
|
||||
// https://vitepress.dev/reference/site-config
|
||||
export default defineConfig({
|
||||
@@ -18,23 +17,25 @@ export default defineConfig({
|
||||
src: '/mnsoftware.png',
|
||||
},
|
||||
nav: [
|
||||
// { text: '文档', link: '/document/index' },
|
||||
// { text: '文档', link: '/src/document/index' },
|
||||
//
|
||||
{ text: 'Devstar', link: '/devstar' },
|
||||
{ text: 'Cloudbuild', link: '/cloudbuild' },
|
||||
{ text: 'Simulator', link: '/simulator' },
|
||||
{ text: 'Enterprise', link: '/enterprise' },
|
||||
{ text: 'DevStar', link: '/src/devstar' },
|
||||
{ text: '编译加速', link: '/src/compile' },
|
||||
{ text: '虚拟仿真', link: '/src/simulator' },
|
||||
{ text: 'Enterprise', link: '/src/enterprise' },
|
||||
],
|
||||
sidebar: {
|
||||
'/devstar/': sidebarDocument(), // 直接返回 SidebarItem[]
|
||||
'/enterprise/': sidebarEnterprise()
|
||||
'/src/devstar/': sidebarDevStar(), // 直接返回 SidebarItem[]
|
||||
'/src/compile/': sidebarCompiling(),
|
||||
'/src/simulator/': sidebarSimulator(),
|
||||
'/src/enterprise/': sidebarEnterprise()
|
||||
},
|
||||
socialLinks: [
|
||||
{ icon: 'github', link: ' https://github.com/mengning/DevStar' }
|
||||
],
|
||||
// footer: [
|
||||
// copyright: 'Copyright © 2025-present devstar contributors',
|
||||
// [Copyright © 2025-present Devstar Contributors](https://github.com/mengning/DevStar)
|
||||
// [Copyright © 2025-present DevStar Contributors](https://github.com/mengning/DevStar)
|
||||
// { copyright: 'Copyright © 2025-present devstar contributors', link: 'https://github.com/mengning/DevStar' }
|
||||
// ] as any,
|
||||
// footer: {
|
||||
@@ -64,32 +65,32 @@ export default defineConfig({
|
||||
}
|
||||
})
|
||||
|
||||
function sidebarDocument(): DefaultTheme.SidebarItem[] {
|
||||
function sidebarDevStar(): DefaultTheme.SidebarItem[] {
|
||||
return [
|
||||
{
|
||||
text: 'Devstar是什么',
|
||||
link: '/devstar/index',
|
||||
items: []
|
||||
text: 'DevStar Studio',
|
||||
link: '/src/devstar/index',
|
||||
items: [
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
text: 'AI+ DevOps',
|
||||
link: '/src/devstar/ai-devops',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: false, // 默认展开
|
||||
items: [
|
||||
{ text: 'AI Code Review', link: '/src/devstar/ai-code-reveiw' },
|
||||
{ text: 'MCP Server', link: '/src/devstar/mcp-server' },
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
text: '安装',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: true, // 默认展开
|
||||
collapsed: false, // 默认展开
|
||||
items: [
|
||||
{ text: '对比Gitea与其它Git托管工具', link: 'https://docs.gitea.com/zh-cn/installation/comparison' },
|
||||
{ text: '数据库准备', link: 'https://docs.gitea.com/zh-cn/installation/database-prep' },
|
||||
// { text: '数据库准备', link: '/document/installation/from-source' },
|
||||
{ text: '使用shell脚本安装', link: '/devstar/installation/install-via-shell-script' },
|
||||
{ text: '使用二进制文件安装', link: 'https://docs.gitea.com/zh-cn/installation/install-from-binary' },
|
||||
{ text: '包管理器安装', link: 'https://docs.gitea.com/zh-cn/installation/install-from-package' },
|
||||
{ text: '使用源代码安装', link: 'https://docs.gitea.com/zh-cn/installation/install-from-source' },
|
||||
{ text: '在Linux中以service方式运行', link: 'https://docs.gitea.com/zh-cn/installation/linux-service' },//
|
||||
{ text: '注册为Windows服务', link: 'https://docs.gitea.com/zh-cn/installation/windows-service' },
|
||||
{ text: '使用Docker安装(rootless)', link: 'https://docs.gitea.com/zh-cn/installation/install-with-docker-rootless' },
|
||||
{ text: '使用Docker安装', link: 'https://docs.gitea.com/zh-cn/installation/install-with-docker' },
|
||||
{ text: '在Kubernetes中安装Gitea', link: 'https://docs.gitea.com/zh-cn/installation/install-on-kubernetes' },
|
||||
{ text: '在云服务器上安装Gitea', link: 'https://docs.gitea.com/zh-cn/installation/install-on-cloud-provider' },
|
||||
{ text: '从旧版Gitea升级', link: 'https://docs.gitea.com/zh-cn/installation/upgrade-from-gitea' },
|
||||
{ text: '快速部署指南', link: 'src/devstar/install/quick-start' },
|
||||
{ text: '云原生环境部署指南', link: 'src/devstar/install/install-k8s' },
|
||||
{ text: 'app.ini配置文件', link: 'src/devstar/install/app-ini' },
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
@@ -123,7 +124,7 @@ function sidebarDocument(): DefaultTheme.SidebarItem[] {
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: true, // 默认展开
|
||||
items: [
|
||||
{ text: '结合AI快速开始', link: 'devstar/usage/quick-start-with-ai' },
|
||||
{ text: 'devcontainer', link: 'src/devstar/usage/quick-start-with-ai' },
|
||||
{
|
||||
text: 'Actions',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
@@ -229,71 +230,110 @@ function sidebarDocument(): DefaultTheme.SidebarItem[] {
|
||||
]
|
||||
}
|
||||
|
||||
function sidebarEnterprise(): DefaultTheme.SidebarItem[] {
|
||||
function sidebarSimulator(): DefaultTheme.SidebarItem[] {
|
||||
return [
|
||||
{
|
||||
text: 'Gitea Enterprise 是什么',
|
||||
link: '/enterprise/index',
|
||||
text: '虚拟仿真技术',
|
||||
link: '/src/simulator/index',
|
||||
items: [
|
||||
|
||||
]
|
||||
},
|
||||
{
|
||||
text: '特征',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: true, // 默认展开
|
||||
text: '虚拟ECU',
|
||||
link: '/src/simulator/vECU',
|
||||
items: [
|
||||
{
|
||||
text: '可继承分支保护',
|
||||
link: 'https://docs.gitea.com/enterprise/features/inheritable-branch-protection'
|
||||
},
|
||||
{
|
||||
text: '依赖关系扫描',
|
||||
link: 'https://docs.gitea.com/enterprise/features/dependency-scan'
|
||||
},
|
||||
{
|
||||
text: 'IP 允许列表',
|
||||
link: 'https://docs.gitea.com/enterprise/features/ip-allowlist'
|
||||
},
|
||||
{
|
||||
text: '企业主题',
|
||||
link: 'https://docs.gitea.com/enterprise/features/enterprise-theme'
|
||||
},
|
||||
{
|
||||
text: '强制2FA身份验证',
|
||||
link: 'https://docs.gitea.com/enterprise/features/mandatory-2fa'
|
||||
},
|
||||
{
|
||||
text: '审计日志',
|
||||
link: 'https://docs.gitea.com/enterprise/features/audit-log'
|
||||
},
|
||||
{
|
||||
text: 'SAML',
|
||||
link: 'https://docs.gitea.com/enterprise/features/saml-auth'
|
||||
},
|
||||
{
|
||||
text: '发布节奏和版本控制',
|
||||
link: 'https://docs.gitea.com/enterprise/features/release-cadence'
|
||||
}
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
text: '安装',
|
||||
link: 'https://docs.gitea.com/enterprise/installation',
|
||||
items: []
|
||||
},
|
||||
{
|
||||
text: '常见问题',
|
||||
link: 'https://docs.gitea.com/enterprise/faq',
|
||||
text: '整车系统级软硬件联合仿真',
|
||||
link: '/src/simulator/vehicle-simulator',
|
||||
items: []
|
||||
},
|
||||
]
|
||||
}
|
||||
|
||||
function sidebarRunner(): DefaultTheme.SidebarItem[] {
|
||||
function sidebarCompiling(): DefaultTheme.SidebarItem[] {
|
||||
return [
|
||||
{
|
||||
link: '/runner/index',
|
||||
text: '编译加速',
|
||||
link: '/src/compile/index',
|
||||
items: [
|
||||
|
||||
]
|
||||
},
|
||||
{
|
||||
text: '分布式编译系统',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: false, // 默认展开
|
||||
items: [
|
||||
{
|
||||
text: '为什么需要分布式编译?',
|
||||
link: '/src/compile/why-distributed-compiling'
|
||||
},
|
||||
{
|
||||
text: 'CloudBuild',
|
||||
link: '/src/compile/cloudbuild'
|
||||
},
|
||||
{
|
||||
text: 'ShareBuild',
|
||||
link: '/src/compile/sharebuild'
|
||||
},
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
text: 'AI Compiler',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: false, // 默认展开
|
||||
items: [
|
||||
{
|
||||
text: 'AI Compiler简介',
|
||||
link: '/src/compile/why-distributed-compiling'
|
||||
},
|
||||
{
|
||||
text: 'CloudBuild',
|
||||
link: '/src/compile/cloudbuild'
|
||||
},
|
||||
{
|
||||
text: 'ShareBuild',
|
||||
link: '/src/compile/sharebuild'
|
||||
},
|
||||
]
|
||||
} as any,
|
||||
{
|
||||
text: 'PGO/LTO',
|
||||
collapsible: true, // 使整个组可折叠
|
||||
collapsed: false, // 默认展开
|
||||
items: [
|
||||
{
|
||||
text: 'PGO/LTO简介',
|
||||
link: '/src/compile/why-distributed-compiling'
|
||||
},
|
||||
{
|
||||
text: 'CloudBuild',
|
||||
link: '/src/compile/cloudbuild'
|
||||
},
|
||||
{
|
||||
text: 'ShareBuild',
|
||||
link: '/src/compile/sharebuild'
|
||||
},
|
||||
]
|
||||
},
|
||||
]
|
||||
}
|
||||
|
||||
function sidebarEnterprise(): DefaultTheme.SidebarItem[] {
|
||||
return [
|
||||
{
|
||||
text: 'DevStar Enterprise',
|
||||
link: '/src/enterprise/index',
|
||||
items: [
|
||||
|
||||
]
|
||||
},
|
||||
{
|
||||
text: '常见问题FAQ',
|
||||
link: '/src/enterprise/faq',
|
||||
items: []
|
||||
},
|
||||
]
|
||||
}
|
||||
@@ -4,7 +4,7 @@ WORKDIR /build-app
|
||||
COPY . .
|
||||
RUN npm install
|
||||
RUN npm add -D vitepress
|
||||
RUN npm run docs:build
|
||||
RUN npm run build
|
||||
|
||||
# 第二阶段:nginx打包
|
||||
FROM nginx:1.25-alpine
|
||||
@@ -15,7 +15,7 @@ COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
# 将第一阶段的静态文件复制到nginx中
|
||||
RUN rm -rf /usr/share/nginx/html
|
||||
RUN mkdir /usr/share/nginx/html
|
||||
COPY --from=frontend-builder /build-app/docs/.vitepress/dist /usr/share/nginx/html
|
||||
COPY --from=frontend-builder /build-app/.vitepress/dist /usr/share/nginx/html
|
||||
|
||||
# 运行
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
|
||||
@@ -9,15 +9,15 @@ npm add -D vitepress
|
||||
|
||||
## 如何启动调试项目
|
||||
```md
|
||||
npm run docs:dev
|
||||
npm run dev
|
||||
```
|
||||
## 如何打包项目
|
||||
```md
|
||||
npm run docs:build
|
||||
npm run build
|
||||
```
|
||||
## 如何预览打包的项目
|
||||
```md
|
||||
npm run docs:preview
|
||||
npm run preview
|
||||
```
|
||||
## 如何添加或修改侧边栏
|
||||
在docs/.vitepress/config.mts中的sidebar进行修改,对于不同路径下的侧边栏,分别使用不同函数得到,text为侧边栏的描述内容,link为点击侧边栏后加载的内容的链接,如果有子目录,在items进行修改
|
||||
|
||||
@@ -1,65 +0,0 @@
|
||||
import path from "node:path";
|
||||
import fs from "node:fs";
|
||||
|
||||
const DIR_PATH = path.resolve("docs");
|
||||
const WHITE_LIST = ["index.md", ".vitepress", "node_modules", ".idea", "assets", "public"];
|
||||
|
||||
const isDirectory = (path) => fs.lstatSync(path).isDirectory();
|
||||
const intersections = (arr1, arr2) =>
|
||||
Array.from(new Set(arr1.filter((item) => !new Set(arr2).has(item))));
|
||||
|
||||
// 新增:按文件系统原始顺序排序
|
||||
const keepOriginalOrder = (files, dirPath) => {
|
||||
return files
|
||||
.map(file => ({
|
||||
name: file,
|
||||
time: fs.statSync(path.join(dirPath, file)).birthtimeMs // 获取创建时间戳
|
||||
}))
|
||||
.sort((a, b) => a.time - b.time) // 按创建时间排序
|
||||
.map(item => item.name);
|
||||
};
|
||||
|
||||
function getList(params, path1, pathname) {
|
||||
const res = [];
|
||||
|
||||
// 修改点1:使用 keepOriginalOrder 保持原始顺序
|
||||
const orderedParams = keepOriginalOrder(params, path1);
|
||||
|
||||
for (let file of orderedParams) { // 修改点2:改用 for...of 遍历
|
||||
const dir = path.join(path1, file);
|
||||
const isDir = isDirectory(dir);
|
||||
|
||||
if (isDir) {
|
||||
const files = fs.readdirSync(dir);
|
||||
res.push({
|
||||
text: file,
|
||||
collapsible: true,
|
||||
items: getList(files, dir, `${pathname}/${file}`),
|
||||
});
|
||||
} else {
|
||||
const suffix = path.extname(file);
|
||||
if (suffix !== ".md") continue;
|
||||
|
||||
const name = path.basename(file, '.md');
|
||||
res.push({
|
||||
text: name,
|
||||
link: `${pathname}/${name}`,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// 修改点3:完全移除 sort() 调用
|
||||
return res;
|
||||
}
|
||||
|
||||
export const set_sidebar = (pathname) => {
|
||||
try {
|
||||
const dirPath = path.join(DIR_PATH, pathname);
|
||||
const files = fs.readdirSync(dirPath);
|
||||
const items = intersections(files, WHITE_LIST);
|
||||
return getList(items, dirPath, pathname);
|
||||
} catch (error) {
|
||||
console.error(`Error generating sidebar for ${pathname}:`, error);
|
||||
return [];
|
||||
}
|
||||
};
|
||||
@@ -5,8 +5,8 @@ layout: home
|
||||
hero:
|
||||
# name: " 通用的"
|
||||
# text: " 为中小型公司提供IT服务"
|
||||
text: "DevStar Studio: The Last Mile of Al for R&D"
|
||||
tagline: 为AI时代打造的新一代智能研发平台,面向人类开发者和AI开发者的融合团队,专注于产品质量和团队效能,为研发部门赋能提效的一站式解决方案
|
||||
text: "The Last Mile of Al for R&D"
|
||||
tagline: DevStar Studio是为AI时代打造的新一代一站式智能研发平台,面向人类开发者和AI开发者的融合团队,专注于产品质量和团队效能,为研发部门赋能提效。
|
||||
image:
|
||||
src: /slider1.png
|
||||
alt: 背景图片
|
||||
@@ -16,7 +16,7 @@ hero:
|
||||
# link: /devstar/index
|
||||
# - theme: alt
|
||||
# text: CloudBuild
|
||||
# link: /cloudbuild/index
|
||||
# link: /compile/index
|
||||
# - theme: alt
|
||||
# text: Simulator
|
||||
# link: /simulator/index
|
||||
@@ -30,7 +30,7 @@ hero:
|
||||
# details: 安装和使用体验良好的详细描述
|
||||
---
|
||||
<script setup>
|
||||
import Index from './components/index.vue' // 你的组件
|
||||
import Index from './src/index.vue' // 你的组件
|
||||
</script>
|
||||
<Index/>
|
||||
|
||||
10
package-lock.json
generated
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "devstar介绍文档",
|
||||
"name": "docs",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
@@ -9,7 +9,7 @@
|
||||
"prismjs": "^1.30.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"vitepress": "^1.6.3"
|
||||
"vitepress": "^1.6.4"
|
||||
}
|
||||
},
|
||||
"node_modules/@algolia/autocomplete-core": {
|
||||
@@ -2291,9 +2291,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/vitepress": {
|
||||
"version": "1.6.3",
|
||||
"resolved": "https://registry.npmmirror.com/vitepress/-/vitepress-1.6.3.tgz",
|
||||
"integrity": "sha512-fCkfdOk8yRZT8GD9BFqusW3+GggWYZ/rYncOfmgcDtP3ualNHCAg+Robxp2/6xfH1WwPHtGpPwv7mbA3qomtBw==",
|
||||
"version": "1.6.4",
|
||||
"resolved": "https://registry.npmjs.org/vitepress/-/vitepress-1.6.4.tgz",
|
||||
"integrity": "sha512-+2ym1/+0VVrbhNyRoFFesVvBvHAVMZMK0rw60E3X/5349M1GuVdKeazuksqopEdvkKwKGs21Q729jX81/bkBJg==",
|
||||
"dev": true,
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"devDependencies": {
|
||||
"vitepress": "^1.6.3"
|
||||
"vitepress": "^1.6.4"
|
||||
},
|
||||
"scripts": {
|
||||
"docs:dev": "vitepress dev docs",
|
||||
"docs:build": "vitepress build docs",
|
||||
"docs:preview": "vitepress preview docs"
|
||||
"dev": "vitepress dev",
|
||||
"build": "vitepress build",
|
||||
"preview": "vitepress preview"
|
||||
},
|
||||
"dependencies": {
|
||||
"@vitejs/plugin-vue": "^6.0.1",
|
||||
|
||||
|
Before Width: | Height: | Size: 68 KiB After Width: | Height: | Size: 68 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 51 KiB After Width: | Height: | Size: 51 KiB |
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 91 KiB |
|
Before Width: | Height: | Size: 151 KiB After Width: | Height: | Size: 151 KiB |
|
Before Width: | Height: | Size: 164 KiB After Width: | Height: | Size: 164 KiB |
|
Before Width: | Height: | Size: 233 KiB After Width: | Height: | Size: 233 KiB |
|
Before Width: | Height: | Size: 39 KiB After Width: | Height: | Size: 39 KiB |
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 1.8 MiB After Width: | Height: | Size: 1.8 MiB |
|
Before Width: | Height: | Size: 556 KiB After Width: | Height: | Size: 556 KiB |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 1.9 MiB |
|
Before Width: | Height: | Size: 2.0 MiB After Width: | Height: | Size: 2.0 MiB |
|
Before Width: | Height: | Size: 51 KiB After Width: | Height: | Size: 51 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 41 KiB After Width: | Height: | Size: 41 KiB |
|
Before Width: | Height: | Size: 164 KiB After Width: | Height: | Size: 164 KiB |
|
Before Width: | Height: | Size: 510 KiB After Width: | Height: | Size: 510 KiB |
|
Before Width: | Height: | Size: 126 KiB After Width: | Height: | Size: 126 KiB |
|
Before Width: | Height: | Size: 941 KiB After Width: | Height: | Size: 941 KiB |
|
Before Width: | Height: | Size: 756 KiB After Width: | Height: | Size: 756 KiB |
|
Before Width: | Height: | Size: 2.5 MiB After Width: | Height: | Size: 2.5 MiB |
|
Before Width: | Height: | Size: 1.4 MiB After Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 156 KiB After Width: | Height: | Size: 156 KiB |
@@ -1,13 +1,13 @@
|
||||
# 分布式编译系统CloudBuild
|
||||

|
||||
## 为什么需要分布式编译技术
|
||||

|
||||
## 为什么需要分布式编译?
|
||||
- 大型项目过长的编译耗时将会给开发、测试和调试都带来延迟,所以缩短大型项目的编译时间的分布式编译系统有重要意义
|
||||
- 使用分布式编译系统编译项目可以利用计算机集群提高编译效率,缩短项目编译时间
|
||||
- 在实际开发时,同一个团队大量的编译任务时相同的。CloudBuild提供的编译缓存可以避免重复上传和重复编译,从而进一步加快编译效率
|
||||
|
||||
## 总体架构
|
||||
### 系统总体架构
|
||||

|
||||

|
||||
- Ninja:客户端,该机器上需要保存有完整的待编译项目源代码。
|
||||
- Action Cache:服务端缓存,主要保存编译任务的执行结果。
|
||||
- CAS Cache:服务端缓存,主要保存客户端上传的依赖文件,编译结果文件。
|
||||
@@ -17,19 +17,19 @@
|
||||
- Executor:各个编译节点
|
||||
|
||||
### 部署示意图
|
||||

|
||||

|
||||
CloudBuild主程序分为三个部分:Client、Server、Executor。
|
||||
- Client:运行在客户端,和用户对接,用于生成待执行的远程编译任务, 同时也作为本地编译节点执行本地任务。
|
||||
- Server:运行在主服务器,主要用于连接各个编译节点,以及 将客户端上传的编译任务调度到与其连接的各个编译节点上。
|
||||
- Executor:运行在编译节点,负责接收并执行编译任务,是编译任务真正执行的地方。
|
||||
|
||||
### 系统分层结构
|
||||

|
||||

|
||||
|
||||
## 运行原理与流程
|
||||
|
||||
### 分布式编译原理
|
||||

|
||||

|
||||
|
||||
### CloudBuild客户端
|
||||
CloudBuild客户端基于Ninja改造,有下面这些优势
|
||||
@@ -54,23 +54,23 @@ CloudBuild客户端基于Ninja改造,有下面这些优势
|
||||
|
||||
## AOSP和LLVM上的应用
|
||||
### LLVM上的应用效果
|
||||

|
||||

|
||||
### AOSP上的应用效果
|
||||

|
||||

|
||||
### CloudBuild硬件资源利用率
|
||||
4核CPU利用率:
|
||||

|
||||

|
||||
8核CPU利用率:
|
||||

|
||||

|
||||
16核CPU利用率:
|
||||

|
||||

|
||||
|
||||
## CloudBuild使用方法
|
||||
### CloudBuild安装
|
||||

|
||||

|
||||
CloudBuild项目地址:https://gitee.com/cloudbuild888/cloudbuild.git
|
||||
### CloudBuild分布式编译
|
||||

|
||||

|
||||
LLVM项目地址:https://gitee.com/mirrors/LLVM.git
|
||||
|
||||
|
||||
82
src/compile/index.md
Normal file
@@ -0,0 +1,82 @@
|
||||
# 编译加速
|
||||
|
||||
|
||||
## 分布式编译技术
|
||||
|
||||

|
||||
|
||||
- 大型项目过长的编译耗时将会给开发、测试和调试都带来延迟,所以缩短大型项目的编译时间的分布式编译系统有重要意义
|
||||
- 使用分布式编译系统编译项目可以利用计算机集群提高编译效率,缩短项目编译时间
|
||||
- 在实际开发时,同一个团队大量的编译任务时相同的。CloudBuild提供的编译缓存可以避免重复上传和重复编译,从而进一步加快编译效率
|
||||
|
||||
### CloudBuild
|
||||

|
||||
- Ninja:客户端,该机器上需要保存有完整的待编译项目源代码。
|
||||
- Action Cache:服务端缓存,主要保存编译任务的执行结果。
|
||||
- CAS Cache:服务端缓存,主要保存客户端上传的依赖文件,编译结果文件。
|
||||
- Scheduler:任务调度器,将编译任务id分发到各个编译节点。
|
||||
- Redis:主要存储具体的编译任务供编译节点领取执行,也可存储Action Cache和 CAS Cache中的内容加速编译。
|
||||
- MySQL:主要存储编译过程中的任务统计信息。
|
||||
- Executor:各个编译节点
|
||||
|
||||
### ShareBuild
|
||||

|
||||
CloudBuild主程序分为三个部分:Client、Server、Executor。
|
||||
- Client:运行在客户端,和用户对接,用于生成待执行的远程编译任务, 同时也作为本地编译节点执行本地任务。
|
||||
- Server:运行在主服务器,主要用于连接各个编译节点,以及 将客户端上传的编译任务调度到与其连接的各个编译节点上。
|
||||
- Executor:运行在编译节点,负责接收并执行编译任务,是编译任务真正执行的地方。
|
||||
|
||||
### 系统分层结构
|
||||

|
||||
|
||||
## 运行原理与流程
|
||||
|
||||
### 分布式编译原理
|
||||

|
||||
|
||||
### CloudBuild客户端
|
||||
CloudBuild客户端基于Ninja改造,有下面这些优势
|
||||
- 兼容使用Ninja编译的项目
|
||||
- 使用远程执行的方式提高编译时并发度
|
||||
- 使用编译缓存减少需要编译的任务数量
|
||||
|
||||
### CloudBuild服务端
|
||||
- 使用远程执行的方法提高编译时并发度,实现了任务分发至远程节点同步执行
|
||||
- 使用分布式任务调度提高任务调度效率和计算节点资源利用率,避免集中式调度的任务阻塞问题
|
||||
- 使用编译缓存结合内容寻址存储技术减少网络传输量、避免重复上传与重复编译
|
||||
|
||||
### CloudBuild优势
|
||||
- 低成本:组成executor的机器不需要使用专门的高性能计算型机器,可使用多个平价的空闲机器
|
||||
- 高效:CloudBuild实现分布式编译的功能,相比单机大大提升并发度
|
||||
- 兼容Ninja:CloudBuild客户端基于Ninja改造,对于使用Ninja构建和可以转换为Ninja构建的项目不用额外修改构建清单
|
||||
|
||||
### CloudBuild执行流程
|
||||
- 客户端: 生成远程任务->生成任务依赖->发送任务与依赖
|
||||
- 服务端:检查任务缓存->检查依赖完整性->调度任务
|
||||
- 编译结点:还原文件目录->还原文件目录->返回编译结果
|
||||
|
||||
## AOSP和LLVM上的应用
|
||||
### LLVM上的应用效果
|
||||

|
||||
### AOSP上的应用效果
|
||||

|
||||
### CloudBuild硬件资源利用率
|
||||
4核CPU利用率:
|
||||

|
||||
8核CPU利用率:
|
||||

|
||||
16核CPU利用率:
|
||||

|
||||
|
||||
## CloudBuild使用方法
|
||||
### CloudBuild安装
|
||||

|
||||
CloudBuild项目地址:https://gitee.com/cloudbuild888/cloudbuild.git
|
||||
### CloudBuild分布式编译
|
||||

|
||||
LLVM项目地址:https://gitee.com/mirrors/LLVM.git
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
79
src/compile/sharebuild.md
Normal file
@@ -0,0 +1,79 @@
|
||||
# 分布式编译系统ShareBuild
|
||||

|
||||
## 为什么需要分布式编译?
|
||||
- 大型项目过长的编译耗时将会给开发、测试和调试都带来延迟,所以缩短大型项目的编译时间的分布式编译系统有重要意义
|
||||
- 使用分布式编译系统编译项目可以利用计算机集群提高编译效率,缩短项目编译时间
|
||||
- 在实际开发时,同一个团队大量的编译任务时相同的。CloudBuild提供的编译缓存可以避免重复上传和重复编译,从而进一步加快编译效率
|
||||
|
||||
## 总体架构
|
||||
### 系统总体架构
|
||||

|
||||
- Ninja:客户端,该机器上需要保存有完整的待编译项目源代码。
|
||||
- Action Cache:服务端缓存,主要保存编译任务的执行结果。
|
||||
- CAS Cache:服务端缓存,主要保存客户端上传的依赖文件,编译结果文件。
|
||||
- Scheduler:任务调度器,将编译任务id分发到各个编译节点。
|
||||
- Redis:主要存储具体的编译任务供编译节点领取执行,也可存储Action Cache和 CAS Cache中的内容加速编译。
|
||||
- MySQL:主要存储编译过程中的任务统计信息。
|
||||
- Executor:各个编译节点
|
||||
|
||||
### 部署示意图
|
||||

|
||||
CloudBuild主程序分为三个部分:Client、Server、Executor。
|
||||
- Client:运行在客户端,和用户对接,用于生成待执行的远程编译任务, 同时也作为本地编译节点执行本地任务。
|
||||
- Server:运行在主服务器,主要用于连接各个编译节点,以及 将客户端上传的编译任务调度到与其连接的各个编译节点上。
|
||||
- Executor:运行在编译节点,负责接收并执行编译任务,是编译任务真正执行的地方。
|
||||
|
||||
### 系统分层结构
|
||||

|
||||
|
||||
## 运行原理与流程
|
||||
|
||||
### 分布式编译原理
|
||||

|
||||
|
||||
### CloudBuild客户端
|
||||
CloudBuild客户端基于Ninja改造,有下面这些优势
|
||||
- 兼容使用Ninja编译的项目
|
||||
- 使用远程执行的方式提高编译时并发度
|
||||
- 使用编译缓存减少需要编译的任务数量
|
||||
|
||||
### CloudBuild服务端
|
||||
- 使用远程执行的方法提高编译时并发度,实现了任务分发至远程节点同步执行
|
||||
- 使用分布式任务调度提高任务调度效率和计算节点资源利用率,避免集中式调度的任务阻塞问题
|
||||
- 使用编译缓存结合内容寻址存储技术减少网络传输量、避免重复上传与重复编译
|
||||
|
||||
### CloudBuild优势
|
||||
- 低成本:组成executor的机器不需要使用专门的高性能计算型机器,可使用多个平价的空闲机器
|
||||
- 高效:CloudBuild实现分布式编译的功能,相比单机大大提升并发度
|
||||
- 兼容Ninja:CloudBuild客户端基于Ninja改造,对于使用Ninja构建和可以转换为Ninja构建的项目不用额外修改构建清单
|
||||
|
||||
### CloudBuild执行流程
|
||||
- 客户端: 生成远程任务->生成任务依赖->发送任务与依赖
|
||||
- 服务端:检查任务缓存->检查依赖完整性->调度任务
|
||||
- 编译结点:还原文件目录->还原文件目录->返回编译结果
|
||||
|
||||
## AOSP和LLVM上的应用
|
||||
### LLVM上的应用效果
|
||||

|
||||
### AOSP上的应用效果
|
||||

|
||||
### CloudBuild硬件资源利用率
|
||||
4核CPU利用率:
|
||||

|
||||
8核CPU利用率:
|
||||

|
||||
16核CPU利用率:
|
||||

|
||||
|
||||
## CloudBuild使用方法
|
||||
### CloudBuild安装
|
||||

|
||||
CloudBuild项目地址:https://gitee.com/cloudbuild888/cloudbuild.git
|
||||
### CloudBuild分布式编译
|
||||

|
||||
LLVM项目地址:https://gitee.com/mirrors/LLVM.git
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
78
src/compile/why-distributed-compiling.md
Normal file
@@ -0,0 +1,78 @@
|
||||
# 为什么需要分布式编译?
|
||||
|
||||
- 大型项目过长的编译耗时将会给开发、测试和调试都带来延迟,所以缩短大型项目的编译时间的分布式编译系统有重要意义
|
||||
- 使用分布式编译系统编译项目可以利用计算机集群提高编译效率,缩短项目编译时间
|
||||
- 在实际开发时,同一个团队大量的编译任务时相同的。CloudBuild提供的编译缓存可以避免重复上传和重复编译,从而进一步加快编译效率
|
||||
|
||||
## 总体架构
|
||||
### 系统总体架构
|
||||

|
||||
- Ninja:客户端,该机器上需要保存有完整的待编译项目源代码。
|
||||
- Action Cache:服务端缓存,主要保存编译任务的执行结果。
|
||||
- CAS Cache:服务端缓存,主要保存客户端上传的依赖文件,编译结果文件。
|
||||
- Scheduler:任务调度器,将编译任务id分发到各个编译节点。
|
||||
- Redis:主要存储具体的编译任务供编译节点领取执行,也可存储Action Cache和 CAS Cache中的内容加速编译。
|
||||
- MySQL:主要存储编译过程中的任务统计信息。
|
||||
- Executor:各个编译节点
|
||||
|
||||
### 部署示意图
|
||||

|
||||
CloudBuild主程序分为三个部分:Client、Server、Executor。
|
||||
- Client:运行在客户端,和用户对接,用于生成待执行的远程编译任务, 同时也作为本地编译节点执行本地任务。
|
||||
- Server:运行在主服务器,主要用于连接各个编译节点,以及 将客户端上传的编译任务调度到与其连接的各个编译节点上。
|
||||
- Executor:运行在编译节点,负责接收并执行编译任务,是编译任务真正执行的地方。
|
||||
|
||||
### 系统分层结构
|
||||

|
||||
|
||||
## 运行原理与流程
|
||||
|
||||
### 分布式编译原理
|
||||

|
||||
|
||||
### CloudBuild客户端
|
||||
CloudBuild客户端基于Ninja改造,有下面这些优势
|
||||
- 兼容使用Ninja编译的项目
|
||||
- 使用远程执行的方式提高编译时并发度
|
||||
- 使用编译缓存减少需要编译的任务数量
|
||||
|
||||
### CloudBuild服务端
|
||||
- 使用远程执行的方法提高编译时并发度,实现了任务分发至远程节点同步执行
|
||||
- 使用分布式任务调度提高任务调度效率和计算节点资源利用率,避免集中式调度的任务阻塞问题
|
||||
- 使用编译缓存结合内容寻址存储技术减少网络传输量、避免重复上传与重复编译
|
||||
|
||||
### CloudBuild优势
|
||||
- 低成本:组成executor的机器不需要使用专门的高性能计算型机器,可使用多个平价的空闲机器
|
||||
- 高效:CloudBuild实现分布式编译的功能,相比单机大大提升并发度
|
||||
- 兼容Ninja:CloudBuild客户端基于Ninja改造,对于使用Ninja构建和可以转换为Ninja构建的项目不用额外修改构建清单
|
||||
|
||||
### CloudBuild执行流程
|
||||
- 客户端: 生成远程任务->生成任务依赖->发送任务与依赖
|
||||
- 服务端:检查任务缓存->检查依赖完整性->调度任务
|
||||
- 编译结点:还原文件目录->还原文件目录->返回编译结果
|
||||
|
||||
## AOSP和LLVM上的应用
|
||||
### LLVM上的应用效果
|
||||

|
||||
### AOSP上的应用效果
|
||||

|
||||
### CloudBuild硬件资源利用率
|
||||
4核CPU利用率:
|
||||

|
||||
8核CPU利用率:
|
||||

|
||||
16核CPU利用率:
|
||||

|
||||
|
||||
## CloudBuild使用方法
|
||||
### CloudBuild安装
|
||||

|
||||
CloudBuild项目地址:https://gitee.com/cloudbuild888/cloudbuild.git
|
||||
### CloudBuild分布式编译
|
||||

|
||||
LLVM项目地址:https://gitee.com/mirrors/LLVM.git
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
32
src/devstar/ai-code-reveiw.md
Normal file
@@ -0,0 +1,32 @@
|
||||
# AI Code Review
|
||||
|
||||
### AI Code Review与CI/CD工作流
|
||||
|
||||
在您的项目中添加.gitea/workflows/code-review.yml , 这里使用kekxv/AiReviewPR@v0.0.6来进行AI Code Review
|
||||
```
|
||||
name: ai-reviews
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, synchronize]
|
||||
|
||||
jobs:
|
||||
review:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Review code
|
||||
uses: kekxv/AiReviewPR@v0.0.6
|
||||
with:
|
||||
model: ${{ vars.MODEL }}
|
||||
host: ${{ vars.OLLAMA_HOST }}
|
||||
REVIEW_PULL_REQUEST: false
|
||||
```
|
||||
DevStar代码托管平台中项目设置、用户设置和后台管理中都可以设置变量vars.MODEL、vars.OLLAMA_HOST等。
|
||||
|
||||
### AI Code Review详解
|
||||
|
||||
161
src/devstar/ai-devops.md
Normal file
@@ -0,0 +1,161 @@
|
||||
# DevStar AI+ DevOps
|
||||
|
||||
DevStar AI+ DevOps 是一个完整的AI驱动研发平台解决方案,通过集成 DevStar平台、代码大语言模型、Gitea MCP Server和 AI Code Tools(Cursor、Claude Code、iFlow等),为开发者提供智能化研发支撑体系。
|
||||
|
||||
## 🚀 快速部署配置指南
|
||||
|
||||
### 一、部署 DevStar 代码托管平台
|
||||
|
||||
Ubuntu-20.04下完成安装:
|
||||
|
||||
```
|
||||
wget -c https://devstar.cn/assets/install.sh && chmod +x install.sh && sudo ./install.sh
|
||||
sudo devstar start
|
||||
```
|
||||
|
||||
安装完成后,我们得到DevStar代码托管平台的URL,比如http://172.16.94.26:80
|
||||
|
||||
### 二、Ollama私有部署代码大模型
|
||||
|
||||
> 如您使用第三方大模型开放API可以跳过这一部分。
|
||||
> 比如从[智谱AI开放平台](https://bigmodel.cn/usercenter/proj-mgmt/apikeys) 上注册申请并添加新的API Key,以Claude Code为例URL使用https://open.bigmodel.cn/api/anthropic
|
||||
|
||||
Ubuntu-20.04下完成安装:
|
||||
```
|
||||
curl -fsSL https://ollama.com/install.sh | sh
|
||||
|
||||
# 验证是否安装成功
|
||||
ollama --version
|
||||
|
||||
# 下载Qwen2.5-Coder大模型
|
||||
ollama pull qwen2.5-coder:32b
|
||||
|
||||
# 列出已下载的模型
|
||||
ollama list
|
||||
|
||||
# 测试模型
|
||||
ollama run qwen2.5-coder:32b "Hello, can you help me code?"
|
||||
|
||||
# 启动Ollama服务 (默认端口11434)
|
||||
ollama serve
|
||||
|
||||
# 验证服务状态
|
||||
curl http://172.16.94.26:11434/api/tags
|
||||
```
|
||||
* 解决Ollama只能本地访问的问题
|
||||
```
|
||||
# 添加环境变量OLLAMA_HOST=0.0.0.0和OLLAMA_ORIGINS=*
|
||||
sed -i '/\[Service\]/a Environment=OLLAMA_HOST=0.0.0.0' /etc/systemd/system/ollama.service
|
||||
sed -i '/\[Service\]/a Environment=OLLAMA_ORIGINS=*' /etc/systemd/system/ollama.service
|
||||
# 重新加载并重启
|
||||
systemctl daemon-reexec
|
||||
systemctl daemon-reload
|
||||
systemctl restart ollama
|
||||
```
|
||||
|
||||
安装完成后,我们得到API URL,比如http://172.16.94.26:11434/api/tags model比如qwen2.5-coder:32b token比如TOKEN***************
|
||||
|
||||
### 三、在项目中使用代码大模型
|
||||
|
||||
#### 配置AI Code Review到CI/CD工作流中
|
||||
|
||||
在您的项目中添加.gitea/workflows/code-review.yml , 这里使用kekxv/AiReviewPR@v0.0.6来进行AI Code Review
|
||||
```
|
||||
name: ai-reviews
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, synchronize]
|
||||
|
||||
jobs:
|
||||
review:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Review code
|
||||
uses: kekxv/AiReviewPR@v0.0.6
|
||||
with:
|
||||
model: ${{ vars.MODEL }}
|
||||
host: ${{ vars.OLLAMA_HOST }}
|
||||
REVIEW_PULL_REQUEST: false
|
||||
```
|
||||
DevStar代码托管平台中项目设置、用户设置和后台管理中都可以设置变量vars.MODEL、vars.OLLAMA_HOST等。
|
||||
|
||||
#### 安装配置MCP Server
|
||||
|
||||
在 VS Code 中使用,要快速安装,请使用如下安装按钮。
|
||||
|
||||
[](https://insiders.vscode.dev/redirect/mcp/install?name=gitea&inputs=[{%22id%22:%22gitea_token%22,%22type%22:%22promptString%22,%22description%22:%22Gitea%20Personal%20Access%20Token%22,%22password%22:true}]&config={%22command%22:%22docker%22,%22args%22:[%22run%22,%22-i%22,%22--rm%22,%22-e%22,%22GITEA_ACCESS_TOKEN%22,%22docker.gitea.com/gitea-mcp-server%22],%22env%22:{%22GITEA_ACCESS_TOKEN%22:%22${input:gitea_token}%22}}) [](https://insiders.vscode.dev/redirect/mcp/install?name=gitea&inputs=[{%22id%22:%22gitea_token%22,%22type%22:%22promptString%22,%22description%22:%22Gitea%20Personal%20Access%20Token%22,%22password%22:true}]&config={%22command%22:%22docker%22,%22args%22:[%22run%22,%22-i%22,%22--rm%22,%22-e%22,%22GITEA_ACCESS_TOKEN%22,%22docker.gitea.com/gitea-mcp-server%22],%22env%22:{%22GITEA_ACCESS_TOKEN%22:%22${input:gitea_token}%22}}&quality=insiders)
|
||||
|
||||
也可以在项目中添加到 .vscode/mcp.json 文件如下:
|
||||
|
||||
```
|
||||
{
|
||||
"mcp": {
|
||||
"inputs": [
|
||||
{
|
||||
"type": "promptString",
|
||||
"id": "gitea_token",
|
||||
"description": "Gitea 个人访问令牌",
|
||||
"password": true
|
||||
}
|
||||
],
|
||||
"servers": {
|
||||
"gitea-mcp": {
|
||||
"command": "docker",
|
||||
"args": [
|
||||
"run",
|
||||
"-i",
|
||||
"--rm",
|
||||
"-e",
|
||||
"GITEA_HOST",
|
||||
"-e",
|
||||
"GITEA_ACCESS_TOKEN",
|
||||
"docker.gitea.com/gitea-mcp-server"
|
||||
],
|
||||
"env": {
|
||||
"GITEA_HOST": "--host http://172.16.94.26",
|
||||
"GITEA_ACCESS_TOKEN": "${input:gitea_token}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
#### 配置AI IDE/CLI使用私有大模型及MCP Server
|
||||
|
||||
* Copilot,简要文字描述,不要上太多图,可以提供官方配置链接
|
||||
* Cursor
|
||||
* Continue
|
||||
* ...
|
||||
|
||||
## 🚀 DevStar AI+ DevOps演示
|
||||
|
||||
在前面部署配置的基础上,我们以VSCode + Copilot或者Continue等为例,演示AI生成代码、触发CI/CD工作流及AI Code Review
|
||||
|
||||
### 创建一个项目
|
||||
|
||||
使用ai-develops项目模板创建项目
|
||||
|
||||
todo
|
||||
|
||||
### AI生成代码
|
||||
|
||||
todo
|
||||
|
||||
### 提交PR
|
||||
|
||||
todo
|
||||
|
||||
### AI Code Review
|
||||
|
||||
todo
|
||||
|
||||
### 合并PR
|
||||
|
||||
todo
|
||||
@@ -3,7 +3,7 @@ outline: deep
|
||||
weight: 1
|
||||
---
|
||||
|
||||
# 关于Devstar
|
||||
# DevStar Studio
|
||||
|
||||
DevStar一站式智能研发平台采用分层架构设计,核心提供DevEnv容器化开发引擎、CI/CD流水线(原生支持Actions和Runners)、Git代码仓库和制品管理功能,上层全面兼容主流IDE(如VSCode、Cursor)和开发工具链,支持C/C++/Go/Rust等语言及ARM/RISC-V/AI芯片开发。平台集成了代码大模型(如DeepSeek、Claude)、MCP服务器集群(包括Github-MCP和DevStar-MCP)、分布式编译服务(CloudBuild/BuildFarm)以及虚拟化平台(QEMU/Renode)等增强功能,底层基于Docker/Kubernetes云原生平台构建,形成从编码、测试到部署的完整研发生态,并通过项目模板生态和应用商店实现开箱即用的开发体验。
|
||||
|
||||
@@ -18,11 +18,11 @@ DevStar Studio是一个通用的一站式软件研发平台,它最初的目标
|
||||
- Git代码托管、镜像仓库等制品管理Releases/Packages、项目管理Projects/Issues、知识管理Wiki等
|
||||
|
||||
## 优势
|
||||
- 验证与开发同步:传统开发流程验证阶段滞后于开发,而Devstar开发流程可以实现“边开发边验证”的并行模式
|
||||
- 集成测试前置:传统开发流程集成测试集中在后期,而Devstar开发流程将集成测试拆解到开发各阶段
|
||||
- 测试条件与实际高度一致:传统开发流程测试环境与真实场景存在差异,而Devstar开发流程可以构建高保真测试环境
|
||||
- 失效迭代前置:传统开发流程失效迭代出现在后期,而Devstar开发流程将失效识别和处理提前到了开发早期
|
||||
- 兼容不容层级的虚拟化:传统开发流程只能保证单一流程的虚拟化,而而Devstar开发流程可同时兼容硬件级虚拟化、系统级虚拟化、进程级虚拟化
|
||||
- 验证与开发同步:传统开发流程验证阶段滞后于开发,而DevStar开发流程可以实现“边开发边验证”的并行模式
|
||||
- 集成测试前置:传统开发流程集成测试集中在后期,而DevStar开发流程将集成测试拆解到开发各阶段
|
||||
- 测试条件与实际高度一致:传统开发流程测试环境与真实场景存在差异,而DevStar开发流程可以构建高保真测试环境
|
||||
- 失效迭代前置:传统开发流程失效迭代出现在后期,而DevStar开发流程将失效识别和处理提前到了开发早期
|
||||
- 兼容不容层级的虚拟化:传统开发流程只能保证单一流程的虚拟化,而而DevStar开发流程可同时兼容硬件级虚拟化、系统级虚拟化、进程级虚拟化
|
||||
|
||||
## 在线演示
|
||||
|
||||
@@ -3,7 +3,7 @@ outline: deep
|
||||
weight: 2
|
||||
---
|
||||
|
||||
# 快速开始
|
||||
# 使用shell脚本安装
|
||||
|
||||
如果您是在Windows环境下,请在cmd命令行下先运行如下命令:
|
||||
```md
|
||||
39
src/devstar/install/quick-start.md
Normal file
@@ -0,0 +1,39 @@
|
||||
---
|
||||
outline: deep
|
||||
weight: 2
|
||||
---
|
||||
|
||||
# 快速开始
|
||||
|
||||
如果您是在Windows环境下,请在cmd命令行下先运行如下命令:
|
||||
```md
|
||||
powershell wsl --install -d Ubuntu-20.04
|
||||
```
|
||||
如果以上命令无法自动完成安装WSL,可以手动执行如下消耗完成命令安装:
|
||||
```md
|
||||
dism.exe /Online /Enable-Feature /FeatureName:Microsoft-Windows-Subsystem-Linux /All /LimitAccess /All
|
||||
dism.exe /Online /Enable-Feature /FeatureName:VirtualMachinePlatform /All /LimitAccess
|
||||
```
|
||||
在Ubuntu-20.04下完成安装:
|
||||
```md
|
||||
wget -c https://devstar.cn/assets/install.sh && chmod +x install.sh && sudo ./install.sh
|
||||
devstar help
|
||||
------------------------------------------------------------------------
|
||||
DevStar usage help:
|
||||
help, -h, --help, Help information
|
||||
start Start DevStar Studio
|
||||
--port=<arg> Specify the port number (default port is 80)
|
||||
--ssh-port=<arg> Specify the ssh-port number (default ssh-port is 2222)
|
||||
--version=<arg> Specify the DevStar Studio Image Version (default verson is latest)
|
||||
--image=<arg> Specify the DevStar Studio Image example: devstar-studio:latest
|
||||
stop Stop the running DevStar Studio
|
||||
logs View the logs of the devstar-studio container
|
||||
clean Clean up the running DevStar Studio, including deleting user data. Please use with caution.
|
||||
------------------------------------------------------------------------
|
||||
sudo devstar start
|
||||
...
|
||||
-------------------------------------------------------
|
||||
DevStar started in http://192.168.234.210:80 successfully!
|
||||
-------------------------------------------------------
|
||||
```
|
||||
然后通过浏览器打开http://192.168.234.210:80 完成后配置安装,默认第一个注册用户为管理员账户。
|
||||
51
src/devstar/mcp-server.md
Normal file
@@ -0,0 +1,51 @@
|
||||
|
||||
# MCP Server
|
||||
|
||||
### 快速安装配置MCP Server
|
||||
|
||||
在 VS Code 中使用,要快速安装,请使用如下安装按钮。
|
||||
|
||||
[](https://insiders.vscode.dev/redirect/mcp/install?name=gitea&inputs=[{%22id%22:%22gitea_token%22,%22type%22:%22promptString%22,%22description%22:%22Gitea%20Personal%20Access%20Token%22,%22password%22:true}]&config={%22command%22:%22docker%22,%22args%22:[%22run%22,%22-i%22,%22--rm%22,%22-e%22,%22GITEA_ACCESS_TOKEN%22,%22docker.gitea.com/gitea-mcp-server%22],%22env%22:{%22GITEA_ACCESS_TOKEN%22:%22${input:gitea_token}%22}}) [](https://insiders.vscode.dev/redirect/mcp/install?name=gitea&inputs=[{%22id%22:%22gitea_token%22,%22type%22:%22promptString%22,%22description%22:%22Gitea%20Personal%20Access%20Token%22,%22password%22:true}]&config={%22command%22:%22docker%22,%22args%22:[%22run%22,%22-i%22,%22--rm%22,%22-e%22,%22GITEA_ACCESS_TOKEN%22,%22docker.gitea.com/gitea-mcp-server%22],%22env%22:{%22GITEA_ACCESS_TOKEN%22:%22${input:gitea_token}%22}}&quality=insiders)
|
||||
|
||||
也可以在项目中添加到 .vscode/mcp.json 文件如下:
|
||||
|
||||
```
|
||||
{
|
||||
"mcp": {
|
||||
"inputs": [
|
||||
{
|
||||
"type": "promptString",
|
||||
"id": "gitea_token",
|
||||
"description": "Gitea 个人访问令牌",
|
||||
"password": true
|
||||
}
|
||||
],
|
||||
"servers": {
|
||||
"gitea-mcp": {
|
||||
"command": "docker",
|
||||
"args": [
|
||||
"run",
|
||||
"-i",
|
||||
"--rm",
|
||||
"-e",
|
||||
"GITEA_HOST",
|
||||
"-e",
|
||||
"GITEA_ACCESS_TOKEN",
|
||||
"docker.gitea.com/gitea-mcp-server"
|
||||
],
|
||||
"env": {
|
||||
"GITEA_HOST": "--host http://172.16.94.26",
|
||||
"GITEA_ACCESS_TOKEN": "${input:gitea_token}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### MCP Server使用注意事项
|
||||
|
||||
* Copilot,简要文字描述,不要上太多图,可以提供官方配置链接
|
||||
* Cursor
|
||||
* Continue
|
||||
* ...
|
||||
52
src/enterprise/faq.md
Normal file
@@ -0,0 +1,52 @@
|
||||
---
|
||||
title: DevStar Enterprise FAG
|
||||
sidebar: auto
|
||||
---
|
||||
|
||||
# DevStar Enterprise FAG
|
||||
|
||||
## 什么是 DevStar Enterprise?
|
||||
|
||||
DevStar Enterprise 是基于开源 Gitea 项目开发的增强版,为企业级用户提供更可靠的体验。
|
||||
|
||||
## 与开源版的关系
|
||||
|
||||
- 基于开源 Gitea 项目开发,操作和配置方式几乎相同
|
||||
- 熟悉 Gitea 的用户可以快速上手 DevStar Enterprise
|
||||
- 企业版专为企业用例需求构建
|
||||
- **注意**:企业版功能需要付费激活
|
||||
|
||||
> 如果您对价格有疑问,可以申请30天免费试用,试用期结束后可选择继续使用(功能将恢复为开源版相同)
|
||||
|
||||
## 定价方案
|
||||
|
||||
您可以在客户门户自主购买 DevStar Enterprise 许可证:
|
||||
|
||||
- 价格基于用户数量,可按实际需求购买
|
||||
- 支持随时"调整"许可证规模(增减用户数或调整时长)
|
||||
- 示例:可将20人12个月许可调整为40人6个月或10人24个月
|
||||
- 调整不产生额外费用
|
||||
- 许可证到期前可选择续订延长有效期
|
||||
- 随时续订可享受促销优惠
|
||||
|
||||
## 版本规则
|
||||
|
||||
DevStar Enterprise 与 Gitea 项目的版本号不同但相互对应:
|
||||
|
||||
- 企业版版本格式:`v21.6.*`
|
||||
- `v21.6` 表示基于 Gitea 1.21.6 版本开发
|
||||
- `.*` 包含企业版特有的补丁或功能更新
|
||||
|
||||
### 版本切换指南
|
||||
|
||||
1. **切换条件**:所有数据和配置完全兼容
|
||||
2. **操作步骤**:只需替换可执行文件或 Docker 镜像
|
||||
3. **版本对应规则**:
|
||||
- 从 Gitea v1.21.6 → 需选择 DevStar Enterprise v21+
|
||||
- 从 DevStar Enterprise v23.1.0 → 需选择 Gitea v1.23+
|
||||
|
||||
## 问题反馈
|
||||
|
||||
大多数问题已在 [FAQ](/src/enterprise/faq) 中解答,如需进一步帮助请联系:
|
||||
|
||||
**邮箱**: [contact@mengning.com.cn](mailto:contact@mengning.com.cn)
|
||||
@@ -1,18 +1,18 @@
|
||||
---
|
||||
title: Gitea Enterprise 介绍
|
||||
title: DevStar Enterprise
|
||||
sidebar: auto
|
||||
---
|
||||
|
||||
# Gitea Enterprise
|
||||
# DevStar Enterprise
|
||||
|
||||
## 什么是 Gitea Enterprise?
|
||||
## 什么是 DevStar Enterprise?
|
||||
|
||||
Gitea Enterprise 是基于开源 Gitea 项目开发的增强版,为企业级用户提供更可靠的体验。
|
||||
DevStar Enterprise 是基于开源 Gitea 项目开发的增强版,为企业级用户提供更可靠的体验。
|
||||
|
||||
## 与开源版的关系
|
||||
|
||||
- 基于开源 Gitea 项目开发,操作和配置方式几乎相同
|
||||
- 熟悉 Gitea 的用户可以快速上手 Gitea Enterprise
|
||||
- 熟悉 Gitea 的用户可以快速上手 DevStar Enterprise
|
||||
- 企业版专为企业用例需求构建
|
||||
- **注意**:企业版功能需要付费激活
|
||||
|
||||
@@ -20,7 +20,7 @@ Gitea Enterprise 是基于开源 Gitea 项目开发的增强版,为企业级
|
||||
|
||||
## 定价方案
|
||||
|
||||
您可以在客户门户自主购买 Gitea Enterprise 许可证:
|
||||
您可以在客户门户自主购买 DevStar Enterprise 许可证:
|
||||
|
||||
- 价格基于用户数量,可按实际需求购买
|
||||
- 支持随时"调整"许可证规模(增减用户数或调整时长)
|
||||
@@ -31,7 +31,7 @@ Gitea Enterprise 是基于开源 Gitea 项目开发的增强版,为企业级
|
||||
|
||||
## 版本规则
|
||||
|
||||
Gitea Enterprise 与 Gitea 项目的版本号不同但相互对应:
|
||||
DevStar Enterprise 与 Gitea 项目的版本号不同但相互对应:
|
||||
|
||||
- 企业版版本格式:`v21.6.*`
|
||||
- `v21.6` 表示基于 Gitea 1.21.6 版本开发
|
||||
@@ -42,11 +42,11 @@ Gitea Enterprise 与 Gitea 项目的版本号不同但相互对应:
|
||||
1. **切换条件**:所有数据和配置完全兼容
|
||||
2. **操作步骤**:只需替换可执行文件或 Docker 镜像
|
||||
3. **版本对应规则**:
|
||||
- 从 Gitea v1.21.6 → 需选择 Gitea Enterprise v21+
|
||||
- 从 Gitea Enterprise v23.1.0 → 需选择 Gitea v1.23+
|
||||
- 从 Gitea v1.21.6 → 需选择 DevStar Enterprise v21+
|
||||
- 从 DevStar Enterprise v23.1.0 → 需选择 Gitea v1.23+
|
||||
|
||||
## 问题反馈
|
||||
|
||||
大多数问题已在 [FAQ](https://docs.gitea.com/enterprise/faq) 中解答,如需进一步帮助请联系:
|
||||
大多数问题已在 [FAQ](/src/enterprise/faq) 中解答,如需进一步帮助请联系:
|
||||
|
||||
**邮箱**: [support@example.com](mailto:support@example.com)
|
||||
**邮箱**: [contact@mengning.com.cn](mailto:contact@mengning.com.cn)
|
||||
@@ -3,7 +3,7 @@
|
||||
<div class="ten_main">
|
||||
<div class="ten_links">
|
||||
<a
|
||||
href="/devstar"
|
||||
href="/src/devstar/ai-devops"
|
||||
class="ten_img"
|
||||
@mouseenter="hoverItem = 'about'"
|
||||
@mouseleave="hoverItem = null"
|
||||
@@ -15,12 +15,12 @@
|
||||
:class="{ 'image-hover': hoverItem === 'about' }"
|
||||
>
|
||||
<div class="ten_img_txt" :class="{ 'text-hover': hoverItem === 'about' }">
|
||||
<h2>Devstar Studio</h2>
|
||||
<h2>AI+ DevOps</h2>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
<a
|
||||
href="/cloudbuild"
|
||||
href="/src/compile"
|
||||
class="ten_img"
|
||||
@mouseenter="hoverItem = 'culture'"
|
||||
@mouseleave="hoverItem = null"
|
||||
@@ -32,12 +32,12 @@
|
||||
:class="{ 'image-hover': hoverItem === 'culture' }"
|
||||
>
|
||||
<div class="ten_img_txt" :class="{ 'text-hover': hoverItem === 'culture' }">
|
||||
<h2>Cloudbuild</h2>
|
||||
<h2>编译加速</h2>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
<a
|
||||
href="/simulator"
|
||||
href="/src/simulator"
|
||||
class="ten_img"
|
||||
@mouseenter="hoverItem = 'office'"
|
||||
@mouseleave="hoverItem = null"
|
||||
@@ -49,7 +49,7 @@
|
||||
:class="{ 'image-hover': hoverItem === 'office' }"
|
||||
>
|
||||
<div class="ten_img_txt" :class="{ 'text-hover': hoverItem === 'office' }">
|
||||
<h2>Simulator</h2>
|
||||
<h2>虚拟仿真</h2>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
@@ -90,7 +90,7 @@
|
||||
<p>
|
||||
<a href="https://beian.miit.gov.cn/" target="_blank" rel="noopener noreferrer">苏ICP备2024068144号-1</a>
|
||||
©
|
||||
<a href="/copyright" rel="noopener noreferrer">Mengning Software</a>.
|
||||
<a href="/src/copyright" rel="noopener noreferrer">Mengning Software</a>.
|
||||
2025- All rights reserved.
|
||||
</p>
|
||||
</div>
|
||||
17
src/simulator/index.md
Normal file
@@ -0,0 +1,17 @@
|
||||
# 虚拟仿真技术概述
|
||||
|
||||

|
||||
|
||||
## 从vECU到整车仿真
|
||||

|
||||
<br>
|
||||
<br>
|
||||
|
||||

|
||||
|
||||
## 整车系统级软硬件联合仿真
|
||||

|
||||
应用场景
|
||||
- 算法及软件的快速测试验证:用台架RT-ECU作为开发控制器的快速样件
|
||||
- 控制器的常规HIL测试
|
||||
- 整车级多控制器的交互测试
|
||||
16
src/simulator/vehicle-simulator.md
Normal file
@@ -0,0 +1,16 @@
|
||||
# simulator
|
||||

|
||||
|
||||
## 从vECU到整车仿真
|
||||

|
||||
<br>
|
||||
<br>
|
||||
|
||||

|
||||
|
||||
## 整车系统级软硬件联合仿真
|
||||

|
||||
应用场景
|
||||
- 算法及软件的快速测试验证:用台架RT-ECU作为开发控制器的快速样件
|
||||
- 控制器的常规HIL测试
|
||||
- 整车级多控制器的交互测试
|
||||