Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 51c18df

Browse files
Send al VPC CNI logs to /dev/null by default (#2443)
1 parent d647b0d commit 51c18df

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

‎python/client/cortex/binary/__init__.py‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,10 @@ def run():
2525
Runs the CLI from terminal.
2626
"""
2727
try:
28-
process = subprocess.run([get_cli_path()] + sys.argv[1:], cwd=os.getcwd())
28+
env = os.environ.copy()
29+
if "AWS_VPC_K8S_CNI_LOG_FILE" not in env:
30+
env["AWS_VPC_K8S_CNI_LOG_FILE"] = "/dev/null"
31+
process = subprocess.run([get_cli_path()] + sys.argv[1:], cwd=os.getcwd(), env=env)
2932
except KeyboardInterrupt:
3033
sys.exit(130) # Ctrl + C
3134
sys.exit(process.returncode)
@@ -51,6 +54,8 @@ def run_cli(
5154

5255
env = os.environ.copy()
5356
env["CORTEX_CLI_INVOKER"] = "python"
57+
if "AWS_VPC_K8S_CNI_LOG_FILE" not in env:
58+
env["AWS_VPC_K8S_CNI_LOG_FILE"] = "/dev/null"
5459
process = subprocess.Popen(
5560
[get_cli_path()] + args,
5661
stderr=subprocess.PIPE,

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /