Skip to content

Commit

Permalink
adding option to exclude dockercloud containers
Browse files Browse the repository at this point in the history
  • Loading branch information
charlyF committed Feb 8, 2018
1 parent 7442be3 commit 1aa43d4
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions utils/dockerutil.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ class CGroupException(Exception):
# only used if no exclude rule was defined
DEFAULT_CONTAINER_EXCLUDE = ["docker_image:gcr.io/google_containers/pause.*", "image_name:openshift/origin-pod"]

# only used for docer cloud users not willing to monitor the underlying containers of the docker cloud agent.
DOCKERCLOUD_EXCLUDE = ["docker_image:dockercloud/.*"]

log = logging.getLogger(__name__)


Expand Down Expand Up @@ -108,6 +111,10 @@ def __init__(self, **kwargs):
else:
self.filtering_enabled = True

if instance.get('ignore_docker_cloud_containers'):
self._exclude = DOCKERCLOUD_EXCLUDE
self.filtering_enabled = False

if self.filtering_enabled:
self.build_filters()

Expand Down

0 comments on commit 1aa43d4

Please sign in to comment.