Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
finance-manage
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
finance-oa
finance-manage
Commits
ef4fef3d
Commit
ef4fef3d
authored
Oct 23, 2021
by
RuoYi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update ry.sh.
parent
3dbbc6a2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
21 deletions
+17
-21
ry.bat
ry.bat
+13
-13
ry.sh
ry.sh
+4
-8
No files found.
ry.bat
View file @
ef4fef3d
...
...
@@ -4,36 +4,36 @@ rem jar平
set
AppName
=
ruoyi
-admin
.jar
rem JVM参数
set
JVM_OPTS
=
"-Dname=
%AppName%
-Duser.timezone=Asia/Shanghai -Xms512
M -Xmx512M -XX:PermSize=256M -XX:MaxPermSize=512M
-XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
set
JVM_OPTS
=
"-Dname=
%AppName%
-Duser.timezone=Asia/Shanghai -Xms512
m -Xmx1024m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=512m
-XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
ECHO
.
ECHO
.
ECHO
.
[
1
]
启动
%AppName%
ECHO
.
[
2
]
关闭
%AppName%
ECHO
.
[
3
]
重启
%AppName%
ECHO
.
[
4
]
启动状态
%AppName%
ECHO
.
[
5
]
退 出
ECHO
.
ECHO
.
[
5
]
退 出
ECHO
.
ECHO
.请输入选择项目的序号:
set
/p
ID
=
IF
"
%id%
"
==
"1"
GOTO
start
IF
"
%id%
"
==
"2"
GOTO
stop
IF
"
%id%
"
==
"3"
GOTO
restart
IF
"
%id%
"
==
"1"
GOTO
start
IF
"
%id%
"
==
"2"
GOTO
stop
IF
"
%id%
"
==
"3"
GOTO
restart
IF
"
%id%
"
==
"4"
GOTO
status
IF
"
%id%
"
==
"5"
EXIT
PAUSE
PAUSE
:start
for
/f
"usebackq tokens=1-2"
%%a
in
(
`jps -l
^|
findstr
%AppName%
`
)
do
(
set
pid
=
%%a
set
image_name
=
%%b
)
if
defined
pid
(
echo
%%is
running
PAUSE
)
echo
%%is
running
PAUSE
)
start
javaw
-jar
%JAVA_OPTS%
ruoyi
-admin
.jar
start
javaw
%JAVA_OPTS%
-jar
%AppName%
echo
starting
……
echo
Start
%AppName%
success
...
...
...
@@ -64,4 +64,4 @@ goto:eof
if
not
defined
pid
(
echo
process
%AppName%
is
dead
)
else
(
echo
%image_name%
is
running
)
goto
:eof
\ No newline at end of file
goto
:eof
ry.sh
View file @
ef4fef3d
#!/bin/sh
# author ruoyi
# ./ry.sh start 启动
# ./ry.sh stop 停止
# ./ry.sh restart 重启
# ./ry.sh status 状态
# ./ry.sh start 启动 stop 停止 restart 重启 status 状态
AppName
=
ruoyi-admin.jar
# JVM参数
JVM_OPTS
=
"-Dname=
$AppName
-Duser.timezone=Asia/Shanghai -Xms512
M -Xmx512M -XX:PermSize=256M -XX:MaxPermSize=512M
-XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
JVM_OPTS
=
"-Dname=
$AppName
-Duser.timezone=Asia/Shanghai -Xms512
m -Xmx1024m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=512m
-XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
APP_HOME
=
`
pwd
`
LOG_PATH
=
$APP_HOME
/logs/
$AppName
.log
...
...
@@ -30,7 +26,7 @@ function start()
if
[
x
"
$PID
"
!=
x
""
]
;
then
echo
"
$AppName
is running..."
else
nohup
java
-jar
$JVM_OPTS
target/
$AppName
>
/dev/null 2>&1 &
nohup
java
$JVM_OPTS
-jar
$AppName
>
/dev/null 2>&1 &
echo
"Start
$AppName
success..."
fi
}
...
...
@@ -38,7 +34,7 @@ function start()
function
stop
()
{
echo
"Stop
$AppName
"
PID
=
""
query
(){
PID
=
`
ps
-ef
|grep java|grep
$AppName
|grep
-v
grep
|awk
'{print $2}'
`
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment