The GitHub Actions job "Tests" on airflow.git has failed.
Run started by GitHub user potiuk (triggered by potiuk).

Head commit for run:
3ab832101150342565c8054339d7297322ae3c72 / Jarek Potiuk <[email protected]>
Support DOCKER_HOST variable passing to Breeze commands

In some cases you might want to override the default way how
Docker determines where to connect by seting DOCKER_HOST variable.

This is generally working out of the box by having the variable
set, but then it does not work well with `--builder` settings
in `builder` plugin. This PR adds support for DOCKER_HOST to be added
to all shell and build commands by disabling the builder when the
variable is set and explicit forwarding of the DOCKER_HOST
variable when running docker commands. You can also override the
DOCKER_HOST variable via `--docker-host` command line switch.

Build arguments in Breeze commands have been sorted as well as their
click options as the command option list grew large enough to be
messy if they are not alphabetically sorted.

We also add automated support for docker-in-docker case which we use in
some tests - the Docker-In-Docker should now work in most cases even
if you set DOCKER_HOST:

* if the ~/.docker/run/docker.sock is used - we change the mapping
  of socket to /var/run/docker.sock
* if DOCKER_HOST is not a "unix://" socket, we pass it through
  (hoping it will **just** work as tcp:// or ssh:// - named pipes
  are not forwardeable anyway)
* if Rootless Docker is used, we follow the rootless docker standard
  for XDG_RUNTIME_DIR/docker.sock (fallback to /run/(UID)/docker.sock

Without DOCKER_HOST we just forward /var/run/docker.sock which
should work also on MacOS - with, or without root-owned socket..

This gets a litte tricky because the way it works on MacOS /
DockerDesktop is a little magicalx. If you set DOCKER_HOST manually to
point to your HOME_DIR socket, you are actually supposed to forward
`/var/run/docker.sock` not the original socket because mappings you
define on MacOS are actually the VM mappings (and your home dir is
mounted to VM - EXCEPT the docker socket which is available on the VM as
/var/run/docker.sock)

More about it in this issue: https://github.com/docker/for-mac/issues/6529
Also docs about MacOS Docker: 
https://docs.docker.com/desktop/mac/permission-requirements/

Report URL: https://github.com/apache/airflow/actions/runs/7069523383

With regards,
GitHub Actions via GitBox


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to