Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
J
jumpserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
jumpserver
Commits
a39424ac
Commit
a39424ac
authored
Mar 25, 2018
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] 更新jms脚本
parent
759760e7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
jms
jms
+9
-5
No files found.
jms
View file @
a39424ac
...
@@ -80,10 +80,14 @@ def get_log_file_path(service):
...
@@ -80,10 +80,14 @@ def get_log_file_path(service):
def
get_pid
(
service
):
def
get_pid
(
service
):
pid_file
=
get_pid_file_path
(
service
)
pid_file
=
get_pid_file_path
(
service
)
pid
=
0
if
os
.
path
.
isfile
(
pid_file
):
if
os
.
path
.
isfile
(
pid_file
):
with
open
(
pid_file
)
as
f
:
with
open
(
pid_file
)
as
f
:
return
int
(
f
.
read
()
.
strip
())
try
:
return
0
return
int
(
f
.
read
()
.
strip
())
except
ValueError
:
pass
return
pid
def
is_running
(
s
,
unlink
=
True
):
def
is_running
(
s
,
unlink
=
True
):
...
@@ -282,9 +286,9 @@ if __name__ == '__main__':
...
@@ -282,9 +286,9 @@ if __name__ == '__main__':
parser
=
argparse
.
ArgumentParser
(
parser
=
argparse
.
ArgumentParser
(
description
=
"""
description
=
"""
Jumpserver service control tools;
Jumpserver service control tools;
Example:
\r\n
Example:
\r\n
%(prog)
s start all -d;
%(prog)
s start all -d;
"""
"""
)
)
...
...
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