Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
beat.core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
beat
beat.core
Commits
c73b726a
Commit
c73b726a
authored
6 years ago
by
Samuel GAIST
Browse files
Options
Downloads
Patches
Plain Diff
[dock] Code cleanup
parent
b04a3cdd
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!62
Code cleanup
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
beat/core/dock.py
+7
-7
7 additions, 7 deletions
beat/core/dock.py
with
7 additions
and
7 deletions
beat/core/dock.py
+
7
−
7
View file @
c73b726a
...
...
@@ -49,7 +49,7 @@ import socket
import
tempfile
import
time
import
docker
import
subprocess
as
sp
import
subprocess
as
sp
# nosec
import
logging
from
beat.core
import
stats
...
...
@@ -140,14 +140,14 @@ class Host(object):
self
.
processing_environments
.
keys
(),
)
)[
0
]
except
:
except
IndexError
:
try
:
return
list
(
filter
(
lambda
x
:
x
.
startswith
(
name
+
"
(
"
),
self
.
db_environments
.
keys
()
)
)[
0
]
except
:
except
IndexError
:
return
None
@property
...
...
@@ -245,10 +245,10 @@ class Host(object):
replacement
=
True
else
:
keep
=
True
except
:
except
Exception
:
replacement
=
True
except
:
except
Exception
:
keep
=
True
elif
new_version
is
not
None
:
...
...
@@ -493,7 +493,7 @@ class Host(object):
try
:
return
simplejson
.
loads
(
stdout
)[
0
][
"
State
"
][
"
Status
"
]
except
:
except
Exception
:
return
None
def
logs
(
self
,
container
):
...
...
@@ -569,7 +569,7 @@ class Host(object):
status
=
self
.
wait
(
container
)
output
=
self
.
logs
(
container
)
except
Exception
as
e
:
except
Exception
:
return
1
,
None
finally
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment