Skip to content

Commit 68ba4ea

Browse files
committed
1
1 parent 2575977 commit 68ba4ea

File tree

2,849 files changed

+245051
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,849 files changed

+245051
-0
lines changed

ruoyi-vue-pro/.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.sql linguist-language=java
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
3+
4+
name: Java CI with Maven
5+
6+
on:
7+
push:
8+
branches: [ master ]
9+
# pull_request:
10+
# branches: [ master ]
11+
12+
jobs:
13+
build:
14+
15+
runs-on: ubuntu-latest
16+
17+
strategy:
18+
matrix:
19+
java: [ '8', '11', '17' ]
20+
21+
steps:
22+
- uses: actions/checkout@v2
23+
- name: Set up JDK ${{ matrix.Java }}
24+
uses: actions/setup-java@v2
25+
with:
26+
java-version: ${{ matrix.java }}
27+
distribution: 'temurin'
28+
cache: maven
29+
- name: Build with Maven
30+
run: mvn -B package --file pom.xml -Dmaven.test.skip=true
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: yudao-ui-admin CI
2+
3+
# 在master分支发生push事件时触发。
4+
on:
5+
push:
6+
branches: [ master ]
7+
# pull_request:
8+
# branches: [ master ]
9+
env: # 设置环境变量
10+
TZ: Asia/Shanghai # 时区(设置时区可使页面中的`最近更新时间`使用时区时间)
11+
WORK_DIR: yudao-ui-admin #工作目录
12+
13+
defaults:
14+
run:
15+
shell: bash
16+
working-directory: yudao-ui-admin
17+
18+
jobs:
19+
build: # 自定义名称
20+
runs-on: ubuntu-latest # 运行在虚拟机环境ubuntu-latest
21+
22+
strategy:
23+
matrix:
24+
node-version: [14.x, 16.x]
25+
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
26+
27+
steps:
28+
- name: Checkout # 步骤1
29+
uses: actions/checkout@v2 # 使用的动作。格式:userName/repoName。作用:检出仓库,获取源码。 官方actions库:https://github.com/actions
30+
31+
- name: Install pnpm
32+
uses: pnpm/action-setup@v2.0.1
33+
with:
34+
version: 6.15.1
35+
36+
- name: Set node version to ${{ matrix.node_version }}
37+
uses: actions/setup-node@v2
38+
with:
39+
node-version: ${{ matrix.node_version }}
40+
cache: "yarn"
41+
cache-dependency-path: yudao-ui-admin/yarn.lock
42+
43+
- name: Install deps
44+
run: node --version && yarn --version && yarn install
45+
46+
- name: Build
47+
run: yarn build:prod
48+
49+
# 查看 workflow 的文档来获取更多信息
50+
# @see https://github.com/crazy-max/ghaction-github-pages
51+

ruoyi-vue-pro/.gitignore

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
######################################################################
2+
# Build Tools
3+
4+
.gradle
5+
/build/
6+
!gradle/wrapper/gradle-wrapper.jar
7+
8+
target/
9+
!.mvn/wrapper/maven-wrapper.jar
10+
11+
######################################################################
12+
# IDE
13+
14+
### STS ###
15+
.apt_generated
16+
.classpath
17+
.factorypath
18+
.project
19+
.settings
20+
.springBeans
21+
22+
### IntelliJ IDEA ###
23+
.idea
24+
*.iws
25+
*.iml
26+
*.ipr
27+
28+
### NetBeans ###
29+
nbproject/private/
30+
build/*
31+
nbbuild/
32+
dist/
33+
nbdist/
34+
.nb-gradle/
35+
36+
######################################################################
37+
# Others
38+
*.log
39+
*.xml.versionsBackup
40+
*.swp
41+
42+
!*/build/*.java
43+
!*/build/*.html
44+
!*/build/*.xml
45+
46+
### JRebel ###
47+
rebel.xml

ruoyi-vue-pro/Jenkinsfile

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
#!groovy
2+
pipeline {
3+
4+
agent any
5+
6+
parameters {
7+
string(name: 'TAG_NAME', defaultValue: '', description: '')
8+
}
9+
10+
environment {
11+
// DockerHub 凭证 ID(登录您的 DockerHub)
12+
DOCKER_CREDENTIAL_ID = 'dockerhub-id'
13+
// GitHub 凭证 ID (推送 tag 到 GitHub 仓库)
14+
GITHUB_CREDENTIAL_ID = 'github-id'
15+
// kubeconfig 凭证 ID (访问接入正在运行的 Kubernetes 集群)
16+
KUBECONFIG_CREDENTIAL_ID = 'demo-kubeconfig'
17+
// 镜像的推送
18+
REGISTRY = 'docker.io'
19+
// DockerHub 账号名
20+
DOCKERHUB_NAMESPACE = 'docker_username'
21+
// GitHub 账号名
22+
GITHUB_ACCOUNT = 'https://gitee.com/zhijiantianya/ruoyi-vue-pro'
23+
// 应用名称
24+
APP_NAME = 'yudao-server'
25+
// 应用部署路径
26+
APP_DEPLOY_BASE_DIR = '/media/pi/KINGTON/data/work/projects/'
27+
}
28+
29+
stages {
30+
stage('检出') {
31+
steps {
32+
git url: "https://gitee.com/will-we/ruoyi-vue-pro.git",
33+
branch: "devops"
34+
}
35+
}
36+
37+
stage('构建') {
38+
steps {
39+
// TODO 解决多环境链接、密码不同配置临时方案
40+
sh 'if [ ! -d "' + "${env.HOME}" + '/resources" ];then\n' +
41+
' echo "配置文件不存在无需修改"\n' +
42+
'else\n' +
43+
' cp -rf ' + "${env.HOME}" + '/resources/*.yaml ' + "${env.APP_NAME}" + '/src/main/resources\n' +
44+
' echo "配置文件替换"\n' +
45+
'fi'
46+
sh 'mvn clean package -Dmaven.test.skip=true'
47+
}
48+
}
49+
50+
stage('部署') {
51+
steps {
52+
sh 'cp -f ' + ' bin/deploy.sh ' + "${env.APP_DEPLOY_BASE_DIR}" + "${env.APP_NAME}"
53+
sh 'cp -f ' + "${env.APP_NAME}" + '/target/*.jar ' + "${env.APP_DEPLOY_BASE_DIR}" + "${env.APP_NAME}" +'/build/'
54+
archiveArtifacts "${env.APP_NAME}" + '/target/*.jar'
55+
sh 'chmod +x ' + "${env.APP_DEPLOY_BASE_DIR}" + "${env.APP_NAME}" + '/deploy.sh'
56+
sh 'bash ' + "${env.APP_DEPLOY_BASE_DIR}" + "${env.APP_NAME}" + '/deploy.sh'
57+
}
58+
}
59+
}
60+
}

ruoyi-vue-pro/LICENSE

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2021 ruoyi-vue-pro
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy of
6+
this software and associated documentation files (the "Software"), to deal in
7+
the Software without restriction, including without limitation the rights to
8+
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9+
the Software, and to permit persons to whom the Software is furnished to do so,
10+
subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17+
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19+
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20+
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

0 commit comments

Comments
 (0)