-
Couldn't load subscription status.
- Fork 38
Disable Docker CLI hints #555
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable Docker CLI hints #555
Conversation
| Brilliant thank you so much for this PR. I really like the idea of telling docker to be less verbose. Just taking a very quick look I am wondering if this will really catch all cases we call docker. I didn't know that if you call @ArneTR I would merge for now and then we can write an issue how to maybe use the |
| That the environemnt is passed to the child process is mandatory. For instance if Docker runs in rootless mode it must know where to find the socket. The CLI command would fail if DOCKER_HOST was not set. I also see no security implication by how we currently handle child process generation. The only custom code we allow should run inside the docker containers that are created. So in conclusion: I see setting env={} as more more problematic than helpful.
|
| Actually just as I wrote the post before something came to my mind: I wonder how this PR is working for the tests ... The tests mirror the flow of the runner.py by creating mimic code. See https://github.com/green-coding-berlin/green-metrics-tool/blob/a2b2ceda9ba8599b3985185e5ceae73fa2062380/tests/test_functions.py#L69 If you do not also call the new "step" of the runner there the addition of the ENV var will not be executed in the test. @davidkopp Could it be that you have the ENV var set in your system in the shell already that you call the python process for the tests from? Otherwise I would not know why the tests should behave differntly. If so: Could you please add the line "prepare docker" also in the test_functions.py |
| Only the tests were failing that executed ps = subprocess.run( ['python3', '../runner.py', '--name', RUN_NAME, '--uri', uri ,'--config-override', 'test-config.yml', '--skip-system-checks', '--dev-repeat-run']The tests that are using Tests.run_until(runner, 'setup_services')Nevertheless, I have now added my change also to |
| lgtm. ty! running tests |
| The test failed with some docker problem. Rerunning to check if it was a networking issue |
* main: Hotfix for check on frequency provider Tests run_until must be guard-claused with cleanup routine (#616) Fix check if stderr is empty (#613) Bump uvicorn[standard] from 0.24.0.post1 to 0.25.0 (#612) Fxing the network provider stderror Branch and filename are now always not null (#602) Adds a more elaborate depends_on test Support reading notes from services (#590) docker build command in tests now checks reason for docker build failure. If it is a permission issue with the cache, it will continue the rest of the workflow (#576) Use depends_on for container startup order (refactored) (#593) Bump psycopg[binary] from 3.1.15 to 3.1.16 (#610) Added powercap info to hardware_info (#609) Changed wording for network infrastructure box (#608) Added SIGQUIT to nginx and initi to gunicorn, as we are using bash script in entrypoint (#605) Fix frontend flow menu to wrap automatically (#584) Bump psutil from 5.9.6 to 5.9.7 (#603) Disable Docker CLI hints (#555) Create codeql.yml
Fixes #554
I have chosen the option to disable the Docker CLI hints via the environment variable
DOCKER_CLI_HINTS=falsein the current session.Another option could be to permanently disable them in the Docker settings (
$HOME/.docker/config.json):