Skip to content

Commit

Permalink
Merge pull request Yelp#2 from glance-/quiet
Browse files Browse the repository at this point in the history
Implement --quiet
  • Loading branch information
johanlundberg authored Oct 28, 2019
2 parents 90b89d1 + 2beb848 commit 91611ee
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions docker_custodian/docker_gc.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,9 @@ def main():
timeout=args.timeout,
**kwargs_from_env())

if args.quiet:
log.setLevel(logging.WARNING)

exclude_container_labels = format_exclude_labels(
args.exclude_container_label
)
Expand Down Expand Up @@ -338,6 +341,10 @@ def main():

def get_args(args=None):
parser = argparse.ArgumentParser()
parser.add_argument(
'-q', '--quiet',
action="store_true",
help="Quiet down program, only print warnings and errors")
parser.add_argument(
'--max-container-age',
type=timedelta_type,
Expand Down

0 comments on commit 91611ee

Please sign in to comment.