This is an automated email from the ASF dual-hosted git repository. potiuk pushed a commit to branch v2-8-test in repository https://gitbox.apache.org/repos/asf/airflow.git
commit c80dc98cfc5d39f36ff1866b3e03ea2a7eb077bf Author: Jarek Potiuk <[email protected]> AuthorDate: Mon Nov 27 17:43:37 2023 +0100 Move pre-commit for local-file-mounts to breeze shell (#35878) The pre-commit is moved to be run via breeze shell. The code to do so has been migrated to new breeze command. (cherry picked from commit 07e40bd601e9d2fd6f6326583596d16c4db94eb2) --- BREEZE.rst | 14 ++- CI.rst | 2 +- .../src/airflow_breeze/commands/setup_commands.py | 49 +++++++++++ .../commands/setup_commands_config.py | 2 + dev/breeze/src/airflow_breeze/utils/path_utils.py | 1 + images/breeze/output_setup.svg | 24 +++--- images/breeze/output_setup.txt | 2 +- .../output_setup_check-all-params-in-groups.svg | 6 +- .../output_setup_check-all-params-in-groups.txt | 2 +- .../output_setup_regenerate-command-images.svg | 32 ++++--- .../output_setup_regenerate-command-images.txt | 2 +- .../output_setup_synchronize-local-mounts.svg | 99 ++++++++++++++++++++++ .../output_setup_synchronize-local-mounts.txt | 1 + .../ci/pre_commit/pre_commit_local_yml_mounts.py | 46 +++------- 14 files changed, 214 insertions(+), 68 deletions(-) diff --git a/BREEZE.rst b/BREEZE.rst index ee350cbc8e..a91f1a9119 100644 --- a/BREEZE.rst +++ b/BREEZE.rst @@ -93,6 +93,7 @@ Here is an example configuration with more than 200GB disk space for Docker: - 5. In some cases you might make sure that "Allow the default Docker socket to be used" in "Advanced" tab of "Docker Desktop" settings is checked + .. raw:: html <div align="center"> @@ -1807,7 +1808,7 @@ check if there are any images that need regeneration. :alt: Breeze setup regenerate-command-images Breeze check-all-params-in-groups -................... +................................. When you add a breeze command or modify a parameter, you are also supposed to make sure that "rich groups" for the command is present and that all parameters are assigned to the right group so they can be @@ -1818,6 +1819,17 @@ nicely presented in ``--help`` output. You can check that via ``check-all-params :width: 100% :alt: Breeze setup check-all-params-in-group +Breeze synchronize-local-mounts +............................... + +When you add volumes mounted to docker, they need to be added in ``docker_command_utils.py`` - so that they +are added by plain ``docker`` command, but they also need to be synchronized with ``local.yml``. This can be +done via ``synchronize-local-mounts`` command. + +.. image:: ./images/breeze/output_setup_synchronize-local-mounts.svg + :target: https://raw.githubusercontent.com/apache/airflow/main/images/breeze/output_setup_synchronize-local-mounts.svg + :width: 100% + :alt: Breeze setup synchronize-local-mounts CI tasks -------- diff --git a/CI.rst b/CI.rst index 313802f58f..e8d7200027 100644 --- a/CI.rst +++ b/CI.rst @@ -535,7 +535,7 @@ Depending whether the scripts are run locally via `Breeze <BREEZE.rst>`_ or whet are run in ``Build Images`` or ``Tests`` workflows they can take different values. You can use those variables when you try to reproduce the build locally (alternatively you can pass -those via command line flags passed to ``breeze`` command. +those via corresponding command line flags passed to ``breeze shell`` command. +-----------------------------------------+-------------+--------------+------------+-------------------------------------------------+ | Variable | Local | Build Images | CI | Comment | diff --git a/dev/breeze/src/airflow_breeze/commands/setup_commands.py b/dev/breeze/src/airflow_breeze/commands/setup_commands.py index f8ed16c314..d7d1e2db9d 100644 --- a/dev/breeze/src/airflow_breeze/commands/setup_commands.py +++ b/dev/breeze/src/airflow_breeze/commands/setup_commands.py @@ -47,8 +47,10 @@ from airflow_breeze.utils.common_options import ( from airflow_breeze.utils.confirm import STANDARD_TIMEOUT, Answer, user_confirm from airflow_breeze.utils.console import get_console, get_stderr_console from airflow_breeze.utils.custom_param_types import BetterChoice +from airflow_breeze.utils.docker_command_utils import VOLUMES_FOR_SELECTED_MOUNTS from airflow_breeze.utils.path_utils import ( AIRFLOW_SOURCES_ROOT, + SCRIPTS_CI_DOCKER_COMPOSE_LOCAL_YAML_FILE, get_installation_airflow_sources, get_installation_sources_config_metadata_hash, get_package_setup_metadata_hash, @@ -657,3 +659,50 @@ def regenerate_command_images(command: tuple[str, ...], force: bool, check_only: def check_all_params_in_groups(command: tuple[str, ...]): return_code = check_that_all_params_are_in_groups(commands=command) sys.exit(return_code) + + +def _insert_documentation(file_path: Path, content: list[str], header: str, footer: str): + text = file_path.read_text().splitlines(keepends=True) + replacing = False + result: list[str] = [] + for line in text: + if line.strip().startswith(header.strip()): + replacing = True + result.append(line) + result.extend(content) + if line.strip().startswith(footer.strip()): + replacing = False + if not replacing: + result.append(line) + src = "".join(result) + file_path.write_text(src) + + [email protected]( + name="synchronize-local-mounts", + help="Synchronize local mounts between python files and docker compose yamls.", +) +@option_verbose +@option_dry_run +def synchronize_local_mounts(): + get_console().print("[info]Synchronizing local mounts between python files and docker compose yamls.[/]") + mounts_header = ( + " # START automatically generated volumes from " + "VOLUMES_FOR_SELECTED_MOUNTS in docker_command_utils.py" + ) + mounts_footer = ( + " # END automatically generated volumes from " + "VOLUMES_FOR_SELECTED_MOUNTS in docker_command_utils.py" + ) + prefix = " " + volumes = [] + for src, dest in VOLUMES_FOR_SELECTED_MOUNTS: + volumes.extend( + [ + prefix + "- type: bind\n", + prefix + f" source: ../../../{src}\n", + prefix + f" target: {dest}\n", + ] + ) + _insert_documentation(SCRIPTS_CI_DOCKER_COMPOSE_LOCAL_YAML_FILE, volumes, mounts_header, mounts_footer) + get_console().print("[success]Synchronized local mounts.[/]") diff --git a/dev/breeze/src/airflow_breeze/commands/setup_commands_config.py b/dev/breeze/src/airflow_breeze/commands/setup_commands_config.py index 1da86bb56a..30a67a213c 100644 --- a/dev/breeze/src/airflow_breeze/commands/setup_commands_config.py +++ b/dev/breeze/src/airflow_breeze/commands/setup_commands_config.py @@ -25,6 +25,7 @@ SETUP_COMMANDS: dict[str, str | list[str]] = { "config", "check-all-params-in-groups", "regenerate-command-images", + "synchronize-local-mounts", "command-hash-export", "version", ], @@ -79,5 +80,6 @@ SETUP_PARAMETERS: dict[str, list[dict[str, str | list[str]]]] = { ], }, ], + "breeze setup synchronize-local-mounts": [], "breeze setup version": [], } diff --git a/dev/breeze/src/airflow_breeze/utils/path_utils.py b/dev/breeze/src/airflow_breeze/utils/path_utils.py index cfda50b802..426c95e98b 100644 --- a/dev/breeze/src/airflow_breeze/utils/path_utils.py +++ b/dev/breeze/src/airflow_breeze/utils/path_utils.py @@ -291,6 +291,7 @@ DIST_DIR = AIRFLOW_SOURCES_ROOT / "dist" DOCS_DIR = AIRFLOW_SOURCES_ROOT / "docs" SCRIPTS_CI_DIR = AIRFLOW_SOURCES_ROOT / "scripts" / "ci" SCRIPTS_CI_DOCKER_COMPOSE_DIR = SCRIPTS_CI_DIR / "docker-compose" +SCRIPTS_CI_DOCKER_COMPOSE_LOCAL_YAML_FILE = SCRIPTS_CI_DOCKER_COMPOSE_DIR / "local.yml" GENERATED_DOCKER_COMPOSE_ENV_FILE = SCRIPTS_CI_DOCKER_COMPOSE_DIR / "_generated_docker_compose.env" GENERATED_DOCKER_ENV_FILE = SCRIPTS_CI_DOCKER_COMPOSE_DIR / "_generated_docker.env" GENERATED_DOCKER_LOCK_FILE = SCRIPTS_CI_DOCKER_COMPOSE_DIR / "_generated.lock" diff --git a/images/breeze/output_setup.svg b/images/breeze/output_setup.svg index 9b165e4524..c747a1eea7 100644 --- a/images/breeze/output_setup.svg +++ b/images/breeze/output_setup.svg @@ -1,4 +1,4 @@ -<svg class="rich-terminal" viewBox="0 0 1482 440.4" xmlns="http://www.w3.org/2000/svg"> +<svg class="rich-terminal" viewBox="0 0 1482 464.79999999999995" xmlns="http://www.w3.org/2000/svg"> <!-- Generated with Rich https://www.textualize.io --> <style> @@ -42,7 +42,7 @@ <defs> <clipPath id="breeze-setup-clip-terminal"> - <rect x="0" y="0" width="1463.0" height="389.4" /> + <rect x="0" y="0" width="1463.0" height="413.79999999999995" /> </clipPath> <clipPath id="breeze-setup-line-0"> <rect x="0" y="1.5" width="1464" height="24.65"/> @@ -89,9 +89,12 @@ <clipPath id="breeze-setup-line-14"> <rect x="0" y="343.1" width="1464" height="24.65"/> </clipPath> +<clipPath id="breeze-setup-line-15"> + <rect x="0" y="367.5" width="1464" height="24.65"/> + </clipPath> </defs> - <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="438.4" rx="8"/><text class="breeze-setup-title" fill="#c5c8c6" text-anchor="middle" x="740" y="27">Command: setup</text> + <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="462.8" rx="8"/><text class="breeze-setup-title" fill="#c5c8c6" text-anchor="middle" x="740" y="27">Command: setup</text> <g transform="translate(26,22)"> <circle cx="0" cy="0" r="7" fill="#ff5f57"/> <circle cx="22" cy="0" r="7" fill="#febc2e"/> @@ -110,13 +113,14 @@ </text><text class="breeze-setup-r5" x="0" y="166.4" textLength="12.2" clip-path="url(#breeze-setup-line-6)">│</text><text class="breeze-setup-r4" x="24.4" y="166.4" textLength="12.2" clip-path="url(#breeze-setup-line-6)">-</text><text class="breeze-setup-r4" x="36.6" y="166.4" textLength="61" clip-path="url(#breeze-setup-line-6)">-help</text><text class="breeze-setup-r6" x="122" y="166.4" textLength="24.4" clip-path="url(#breeze-setup-line-6)">-h</text><text class="breeze-setup-r1" x="1 [...] </text><text class="breeze-setup-r5" x="0" y="190.8" textLength="1464" clip-path="url(#breeze-setup-line-7)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-r1" x="1464" y="190.8" textLength="12.2" clip-path="url(#breeze-setup-line-7)"> </text><text class="breeze-setup-r5" x="0" y="215.2" textLength="24.4" clip-path="url(#breeze-setup-line-8)">╭─</text><text class="breeze-setup-r5" x="24.4" y="215.2" textLength="85.4" clip-path="url(#breeze-setup-line-8)"> Setup </text><text class="breeze-setup-r5" x="109.8" y="215.2" textLength="1329.8" clip-path="url(#breeze-setup-line-8)">─────────────────────────────────────────────────────────────────────────────────────────────────────────────</text><text class="breeze-s [...] -</text><text class="breeze-setup-r5" x="0" y="239.6" textLength="12.2" clip-path="url(#breeze-setup-line-9)">│</text><text class="breeze-setup-r4" x="24.4" y="239.6" textLength="402.6" clip-path="url(#breeze-setup-line-9)">autocomplete                     </text><text class="breeze-setup-r1" x="451.4" y="239.6" textLength="988.2" clip-path="url(#breeze-setup-line-9)">Enables auto [...] -</text><text class="breeze-setup-r5" x="0" y="264" textLength="12.2" clip-path="url(#breeze-setup-line-10)">│</text><text class="breeze-setup-r4" x="24.4" y="264" textLength="402.6" clip-path="url(#breeze-setup-line-10)">self-upgrade                     </text><text class="breeze-setup-r1" x="451.4" y="264" textLength="988.2" clip-path="url(#breeze-setup-line-10)">Self upgrade [...] -</text><text class="breeze-setup-r5" x="0" y="288.4" textLength="12.2" clip-path="url(#breeze-setup-line-11)">│</text><text class="breeze-setup-r4" x="24.4" y="288.4" textLength="402.6" clip-path="url(#breeze-setup-line-11)">config                           </text><text class="breeze-setup-r1" x="451.4" y="288.4" textLength="988.2" clip-path="url(#breeze- [...] -</text><text class="breeze-setup-r5" x="0" y="312.8" textLength="12.2" clip-path="url(#breeze-setup-line-12)">│</text><text class="breeze-setup-r4" x="24.4" y="312.8" textLength="402.6" clip-path="url(#breeze-setup-line-12)">check-all-params-in-groups       </text><text class="breeze-setup-r1" x="451.4" y="312.8" textLength="988.2" clip-path="url(#breeze-setup-line-12)">Check that all parameters are put in groups.  [...] -</text><text class="breeze-setup-r5" x="0" y="337.2" textLength="12.2" clip-path="url(#breeze-setup-line-13)">│</text><text class="breeze-setup-r4" x="24.4" y="337.2" textLength="402.6" clip-path="url(#breeze-setup-line-13)">regenerate-command-images        </text><text class="breeze-setup-r1" x="451.4" y="337.2" textLength="988.2" clip-path="url(#breeze-setup-line-13)">Regenerate breeze command images.     & [...] -</text><text class="breeze-setup-r5" x="0" y="361.6" textLength="12.2" clip-path="url(#breeze-setup-line-14)">│</text><text class="breeze-setup-r4" x="24.4" y="361.6" textLength="402.6" clip-path="url(#breeze-setup-line-14)">version                          </text><text class="breeze-setup-r1" x="451.4" y="361.6" textLength="988.2" clip-path="url(#breeze-setup [...] -</text><text class="breeze-setup-r5" x="0" y="386" textLength="1464" clip-path="url(#breeze-setup-line-15)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-r1" x="1464" y="386" textLength="12.2" clip-path="url(#breeze-setup-line-15)"> +</text><text class="breeze-setup-r5" x="0" y="239.6" textLength="12.2" clip-path="url(#breeze-setup-line-9)">│</text><text class="breeze-setup-r4" x="24.4" y="239.6" textLength="378.2" clip-path="url(#breeze-setup-line-9)">autocomplete                   </text><text class="breeze-setup-r1" x="427" y="239.6" textLength="1012.6" clip-path="url(#breeze-setup-line-9)">Enables autocompletion [...] +</text><text class="breeze-setup-r5" x="0" y="264" textLength="12.2" clip-path="url(#breeze-setup-line-10)">│</text><text class="breeze-setup-r4" x="24.4" y="264" textLength="378.2" clip-path="url(#breeze-setup-line-10)">self-upgrade                   </text><text class="breeze-setup-r1" x="427" y="264" textLength="1012.6" clip-path="url(#breeze-setup-line-10)">Self upgrade Breeze. [...] +</text><text class="breeze-setup-r5" x="0" y="288.4" textLength="12.2" clip-path="url(#breeze-setup-line-11)">│</text><text class="breeze-setup-r4" x="24.4" y="288.4" textLength="378.2" clip-path="url(#breeze-setup-line-11)">config                         </text><text class="breeze-setup-r1" x="427" y="288.4" textLength="1012.6" clip-path="url(#breeze-setup-line-11 [...] +</text><text class="breeze-setup-r5" x="0" y="312.8" textLength="12.2" clip-path="url(#breeze-setup-line-12)">│</text><text class="breeze-setup-r4" x="24.4" y="312.8" textLength="378.2" clip-path="url(#breeze-setup-line-12)">check-all-params-in-groups     </text><text class="breeze-setup-r1" x="427" y="312.8" textLength="1012.6" clip-path="url(#breeze-setup-line-12)">Check that all parameters are put in groups.    [...] +</text><text class="breeze-setup-r5" x="0" y="337.2" textLength="12.2" clip-path="url(#breeze-setup-line-13)">│</text><text class="breeze-setup-r4" x="24.4" y="337.2" textLength="378.2" clip-path="url(#breeze-setup-line-13)">regenerate-command-images      </text><text class="breeze-setup-r1" x="427" y="337.2" textLength="1012.6" clip-path="url(#breeze-setup-line-13)">Regenerate breeze command images.       &# [...] +</text><text class="breeze-setup-r5" x="0" y="361.6" textLength="12.2" clip-path="url(#breeze-setup-line-14)">│</text><text class="breeze-setup-r4" x="24.4" y="361.6" textLength="378.2" clip-path="url(#breeze-setup-line-14)">synchronize-local-mounts       </text><text class="breeze-setup-r1" x="427" y="361.6" textLength="1012.6" clip-path="url(#breeze-setup-line-14)">Synchronize local mounts between python files and do [...] +</text><text class="breeze-setup-r5" x="0" y="386" textLength="12.2" clip-path="url(#breeze-setup-line-15)">│</text><text class="breeze-setup-r4" x="24.4" y="386" textLength="378.2" clip-path="url(#breeze-setup-line-15)">version                        </text><text class="breeze-setup-r1" x="427" y="386" textLength="1012.6" clip-path="url(#breeze-setup-line-15)">Print [...] +</text><text class="breeze-setup-r5" x="0" y="410.4" textLength="1464" clip-path="url(#breeze-setup-line-16)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-r1" x="1464" y="410.4" textLength="12.2" clip-path="url(#breeze-setup-line-16)"> </text> </g> </g> diff --git a/images/breeze/output_setup.txt b/images/breeze/output_setup.txt index 47cbfbccca..b8f9048b91 100644 --- a/images/breeze/output_setup.txt +++ b/images/breeze/output_setup.txt @@ -1 +1 @@ -f7bc45512df20d7ddcbcc09070d0eae4 +d4a4f1b405f912fa234ff4116068290a diff --git a/images/breeze/output_setup_check-all-params-in-groups.svg b/images/breeze/output_setup_check-all-params-in-groups.svg index 7cbbe80389..cd1e29e11b 100644 --- a/images/breeze/output_setup_check-all-params-in-groups.svg +++ b/images/breeze/output_setup_check-all-params-in-groups.svg @@ -173,9 +173,9 @@ </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="508" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-20)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="508" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-20)">release-management:update-constraints | release-management:verify-provider-packages | sbom |        [...] </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="532.4" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-21)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="532.4" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-21)">sbom:build-all-airflow-images | sbom:generate-providers-requirements | sbom:update-sbom-information |  </text><text class="b [...] </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="556.8" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-22)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="556.8" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-22)">setup | setup:autocomplete | setup:check-all-params-in-groups | setup:config |        [...] -</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="581.2" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-23)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="581.2" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-23)">setup:regenerate-command-images | setup:self-upgrade | setup:version | shell | start-airflow |   &# [...] -</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="605.6" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-24)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="605.6" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-24)">static-checks | testing | testing:db-tests | testing:docker-compose-tests | testing:helm-tests |    [...] -</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="630" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-25)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="630" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-25)">testing:integration-tests | testing:non-db-tests | testing:tests)              [...] +</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="581.2" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-23)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="581.2" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-23)">setup:regenerate-command-images | setup:self-upgrade | setup:synchronize-local-mounts | setup:version |</text><text class="b [...] +</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="605.6" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-24)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="605.6" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-24)">shell | start-airflow | static-checks | testing | testing:db-tests | testing:docker-compose-tests |  [...] +</text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="630" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-25)">│</text><text class="breeze-setup-check-all-params-in-groups-r6" x="183" y="630" textLength="1256.6" clip-path="url(#breeze-setup-check-all-params-in-groups-line-25)">testing:helm-tests | testing:integration-tests | testing:non-db-tests | testing:tests)         [...] </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="654.4" textLength="1464" clip-path="url(#breeze-setup-check-all-params-in-groups-line-26)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-check-all-params-in-groups-r1" x="1464" y="654.4" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-26)"> </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="678.8" textLength="24.4" clip-path="url(#breeze-setup-check-all-params-in-groups-line-27)">╭─</text><text class="breeze-setup-check-all-params-in-groups-r5" x="24.4" y="678.8" textLength="195.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-27)"> Common options </text><text class="breeze-setup-check-all-params-in-groups-r5" x="219.6" y="678.8" textLength="1220" clip-path="url(#breeze-se [...] </text><text class="breeze-setup-check-all-params-in-groups-r5" x="0" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-28)">│</text><text class="breeze-setup-check-all-params-in-groups-r4" x="24.4" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-check-all-params-in-groups-line-28)">-</text><text class="breeze-setup-check-all-params-in-groups-r4" x="36.6" y="703.2" textLength="97.6" clip-path="url(#breeze-setup-check-all-params-in-groups-li [...] diff --git a/images/breeze/output_setup_check-all-params-in-groups.txt b/images/breeze/output_setup_check-all-params-in-groups.txt index bd16df6cd4..5d60a82702 100644 --- a/images/breeze/output_setup_check-all-params-in-groups.txt +++ b/images/breeze/output_setup_check-all-params-in-groups.txt @@ -1 +1 @@ -987e89df80114d4b5bc7fa4a3ba6d569 +dc5302a16d491b4567469e6e1b562186 diff --git a/images/breeze/output_setup_regenerate-command-images.svg b/images/breeze/output_setup_regenerate-command-images.svg index d3fd828808..d6195eb298 100644 --- a/images/breeze/output_setup_regenerate-command-images.svg +++ b/images/breeze/output_setup_regenerate-command-images.svg @@ -1,4 +1,4 @@ -<svg class="rich-terminal" viewBox="0 0 1482 904.0" xmlns="http://www.w3.org/2000/svg"> +<svg class="rich-terminal" viewBox="0 0 1482 928.4" xmlns="http://www.w3.org/2000/svg"> <!-- Generated with Rich https://www.textualize.io --> <style> @@ -43,7 +43,7 @@ <defs> <clipPath id="breeze-setup-regenerate-command-images-clip-terminal"> - <rect x="0" y="0" width="1463.0" height="853.0" /> + <rect x="0" y="0" width="1463.0" height="877.4" /> </clipPath> <clipPath id="breeze-setup-regenerate-command-images-line-0"> <rect x="0" y="1.5" width="1464" height="24.65"/> @@ -147,9 +147,12 @@ <clipPath id="breeze-setup-regenerate-command-images-line-33"> <rect x="0" y="806.7" width="1464" height="24.65"/> </clipPath> +<clipPath id="breeze-setup-regenerate-command-images-line-34"> + <rect x="0" y="831.1" width="1464" height="24.65"/> + </clipPath> </defs> - <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="902" rx="8"/><text class="breeze-setup-regenerate-command-images-title" fill="#c5c8c6" text-anchor="middle" x="740" y="27">Command: setup regenerate-command-images</text> + <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="926.4" rx="8"/><text class="breeze-setup-regenerate-command-images-title" fill="#c5c8c6" text-anchor="middle" x="740" y="27">Command: setup regenerate-command-images</text> <g transform="translate(26,22)"> <circle cx="0" cy="0" r="7" fill="#ff5f57"/> <circle cx="22" cy="0" r="7" fill="#febc2e"/> @@ -183,17 +186,18 @@ </text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="532.4" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-21)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="532.4" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-21)">release-management:update-constraints | release-management:verify-provider-packages | sbom |        [...] </text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="556.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-22)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="556.8" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-22)">sbom:build-all-airflow-images | sbom:generate-providers-requirements | sbom:update-sbom-information </text><text class="breeze-setup-regen [...] </text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="581.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-23)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="581.2" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-23)">| setup | setup:autocomplete | setup:check-all-params-in-groups | setup:config |       & [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="605.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-24)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="605.6" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-24)">setup:regenerate-command-images | setup:self-upgrade | setup:version | shell | start-airflow |     [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="630" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-25)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="630" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-25)">static-checks | testing | testing:db-tests | testing:docker-compose-tests | testing:helm-tests |    </ [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="654.4" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-26)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="654.4" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-26)">testing:integration-tests | testing:non-db-tests | testing:tests)              [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="678.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-27)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="678.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-27)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="678.8" textLength="73.2" clip-path="url(#breeze-setup-regenerate-command-images-line-27) [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-28)">│</text><text class="breeze-setup-regenerate-command-images-r1" x="219.6" y="703.2" textLength="170.8" clip-path="url(#breeze-setup-regenerate-command-images-line-28)">together with </text><text class="breeze-setup-regenerate-command-images-r4" x="390.4" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-regenera [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="727.6" textLength="1464" clip-path="url(#breeze-setup-regenerate-command-images-line-29)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-regenerate-command-images-r1" x="1464" y="727.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-29)"> -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="752" textLength="24.4" clip-path="url(#breeze-setup-regenerate-command-images-line-30)">╭─</text><text class="breeze-setup-regenerate-command-images-r5" x="24.4" y="752" textLength="195.2" clip-path="url(#breeze-setup-regenerate-command-images-line-30)"> Common options </text><text class="breeze-setup-regenerate-command-images-r5" x="219.6" y="752" textLength="1220" clip-path="url(#breeze-setup-regener [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="776.4" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-31)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="776.4" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-31)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="776.4" textLength="97.6" clip-path="url(#breeze-setup-regenerate-command-images-line-31) [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="800.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-32)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="800.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-32)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="800.8" textLength="48.8" clip-path="url(#breeze-setup-regenerate-command-images-line-32) [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="825.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-33)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="825.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-33)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="825.2" textLength="61" clip-path="url(#breeze-setup-regenerate-command-images-line-33)"> [...] -</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="849.6" textLength="1464" clip-path="url(#breeze-setup-regenerate-command-images-line-34)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-regenerate-command-images-r1" x="1464" y="849.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-34)"> +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="605.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-24)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="605.6" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-24)">setup:regenerate-command-images | setup:self-upgrade | setup:synchronize-local-mounts |         [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="630" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-25)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="630" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-25)">setup:version | shell | start-airflow | static-checks | testing | testing:db-tests |     [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="654.4" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-26)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="654.4" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-26)">testing:docker-compose-tests | testing:helm-tests | testing:integration-tests | testing:non-db-tests</text><text class="breeze-setup- [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="678.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-27)">│</text><text class="breeze-setup-regenerate-command-images-r6" x="219.6" y="678.8" textLength="1220" clip-path="url(#breeze-setup-regenerate-command-images-line-27)">| testing:tests)                        [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-28)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="703.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-28)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="703.2" textLength="73.2" clip-path="url(#breeze-setup-regenerate-command-images-line-28) [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="727.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-29)">│</text><text class="breeze-setup-regenerate-command-images-r1" x="219.6" y="727.6" textLength="170.8" clip-path="url(#breeze-setup-regenerate-command-images-line-29)">together with </text><text class="breeze-setup-regenerate-command-images-r4" x="390.4" y="727.6" textLength="12.2" clip-path="url(#breeze-setup-regenera [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="752" textLength="1464" clip-path="url(#breeze-setup-regenerate-command-images-line-30)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-regenerate-command-images-r1" x="1464" y="752" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-30)"> +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="776.4" textLength="24.4" clip-path="url(#breeze-setup-regenerate-command-images-line-31)">╭─</text><text class="breeze-setup-regenerate-command-images-r5" x="24.4" y="776.4" textLength="195.2" clip-path="url(#breeze-setup-regenerate-command-images-line-31)"> Common options </text><text class="breeze-setup-regenerate-command-images-r5" x="219.6" y="776.4" textLength="1220" clip-path="url(#breeze-setup-r [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="800.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-32)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="800.8" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-32)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="800.8" textLength="97.6" clip-path="url(#breeze-setup-regenerate-command-images-line-32) [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="825.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-33)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="825.2" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-33)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="825.2" textLength="48.8" clip-path="url(#breeze-setup-regenerate-command-images-line-33) [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="849.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-34)">│</text><text class="breeze-setup-regenerate-command-images-r4" x="24.4" y="849.6" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-34)">-</text><text class="breeze-setup-regenerate-command-images-r4" x="36.6" y="849.6" textLength="61" clip-path="url(#breeze-setup-regenerate-command-images-line-34)"> [...] +</text><text class="breeze-setup-regenerate-command-images-r5" x="0" y="874" textLength="1464" clip-path="url(#breeze-setup-regenerate-command-images-line-35)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-regenerate-command-images-r1" x="1464" y="874" textLength="12.2" clip-path="url(#breeze-setup-regenerate-command-images-line-35)"> </text> </g> </g> diff --git a/images/breeze/output_setup_regenerate-command-images.txt b/images/breeze/output_setup_regenerate-command-images.txt index 839aad6c8c..68d92674a7 100644 --- a/images/breeze/output_setup_regenerate-command-images.txt +++ b/images/breeze/output_setup_regenerate-command-images.txt @@ -1 +1 @@ -7b3dba4e15361b982859694ae2822891 +97c8fd408d3b874a2939958c0dbd2029 diff --git a/images/breeze/output_setup_synchronize-local-mounts.svg b/images/breeze/output_setup_synchronize-local-mounts.svg new file mode 100644 index 0000000000..39d59dd8cd --- /dev/null +++ b/images/breeze/output_setup_synchronize-local-mounts.svg @@ -0,0 +1,99 @@ +<svg class="rich-terminal" viewBox="0 0 1482 294.0" xmlns="http://www.w3.org/2000/svg"> + <!-- Generated with Rich https://www.textualize.io --> + <style> + + @font-face { + font-family: "Fira Code"; + src: local("FiraCode-Regular"), + url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff2/FiraCode-Regular.woff2") format("woff2"), + url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff/FiraCode-Regular.woff") format("woff"); + font-style: normal; + font-weight: 400; + } + @font-face { + font-family: "Fira Code"; + src: local("FiraCode-Bold"), + url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff2/FiraCode-Bold.woff2") format("woff2"), + url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff/FiraCode-Bold.woff") format("woff"); + font-style: bold; + font-weight: 700; + } + + .breeze-setup-synchronize-local-mounts-matrix { + font-family: Fira Code, monospace; + font-size: 20px; + line-height: 24.4px; + font-variant-east-asian: full-width; + } + + .breeze-setup-synchronize-local-mounts-title { + font-size: 18px; + font-weight: bold; + font-family: arial; + } + + .breeze-setup-synchronize-local-mounts-r1 { fill: #c5c8c6 } +.breeze-setup-synchronize-local-mounts-r2 { fill: #d0b344 } +.breeze-setup-synchronize-local-mounts-r3 { fill: #c5c8c6;font-weight: bold } +.breeze-setup-synchronize-local-mounts-r4 { fill: #68a0b3;font-weight: bold } +.breeze-setup-synchronize-local-mounts-r5 { fill: #868887 } +.breeze-setup-synchronize-local-mounts-r6 { fill: #98a84b;font-weight: bold } + </style> + + <defs> + <clipPath id="breeze-setup-synchronize-local-mounts-clip-terminal"> + <rect x="0" y="0" width="1463.0" height="243.0" /> + </clipPath> + <clipPath id="breeze-setup-synchronize-local-mounts-line-0"> + <rect x="0" y="1.5" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-1"> + <rect x="0" y="25.9" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-2"> + <rect x="0" y="50.3" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-3"> + <rect x="0" y="74.7" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-4"> + <rect x="0" y="99.1" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-5"> + <rect x="0" y="123.5" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-6"> + <rect x="0" y="147.9" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-7"> + <rect x="0" y="172.3" width="1464" height="24.65"/> + </clipPath> +<clipPath id="breeze-setup-synchronize-local-mounts-line-8"> + <rect x="0" y="196.7" width="1464" height="24.65"/> + </clipPath> + </defs> + + <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="292" rx="8"/><text class="breeze-setup-synchronize-local-mounts-title" fill="#c5c8c6" text-anchor="middle" x="740" y="27">Command: setup synchronize-local-mounts</text> + <g transform="translate(26,22)"> + <circle cx="0" cy="0" r="7" fill="#ff5f57"/> + <circle cx="22" cy="0" r="7" fill="#febc2e"/> + <circle cx="44" cy="0" r="7" fill="#28c840"/> + </g> + + <g transform="translate(9, 41)" clip-path="url(#breeze-setup-synchronize-local-mounts-clip-terminal)"> + + <g class="breeze-setup-synchronize-local-mounts-matrix"> + <text class="breeze-setup-synchronize-local-mounts-r1" x="1464" y="20" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-0)"> +</text><text class="breeze-setup-synchronize-local-mounts-r2" x="12.2" y="44.4" textLength="73.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-1)">Usage:</text><text class="breeze-setup-synchronize-local-mounts-r3" x="97.6" y="44.4" textLength="451.4" clip-path="url(#breeze-setup-synchronize-local-mounts-line-1)">breeze setup synchronize-local-mounts</text><text class="breeze-setup-synchronize-local-mounts-r1" x="561.2" y="44.4" textLength="12.2" clip-path="url(#b [...] +</text><text class="breeze-setup-synchronize-local-mounts-r1" x="1464" y="68.8" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-2)"> +</text><text class="breeze-setup-synchronize-local-mounts-r1" x="12.2" y="93.2" textLength="866.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-3)">Synchronize local mounts between python files and docker compose yamls.</text><text class="breeze-setup-synchronize-local-mounts-r1" x="1464" y="93.2" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-3)"> +</text><text class="breeze-setup-synchronize-local-mounts-r1" x="1464" y="117.6" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-4)"> +</text><text class="breeze-setup-synchronize-local-mounts-r5" x="0" y="142" textLength="24.4" clip-path="url(#breeze-setup-synchronize-local-mounts-line-5)">╭─</text><text class="breeze-setup-synchronize-local-mounts-r5" x="24.4" y="142" textLength="195.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-5)"> Common options </text><text class="breeze-setup-synchronize-local-mounts-r5" x="219.6" y="142" textLength="1220" clip-path="url(#breeze-setup-synchronize-lo [...] +</text><text class="breeze-setup-synchronize-local-mounts-r5" x="0" y="166.4" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-6)">│</text><text class="breeze-setup-synchronize-local-mounts-r4" x="24.4" y="166.4" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-6)">-</text><text class="breeze-setup-synchronize-local-mounts-r4" x="36.6" y="166.4" textLength="97.6" clip-path="url(#breeze-setup-synchronize-local-mounts-line-6)">-verbos [...] +</text><text class="breeze-setup-synchronize-local-mounts-r5" x="0" y="190.8" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-7)">│</text><text class="breeze-setup-synchronize-local-mounts-r4" x="24.4" y="190.8" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-7)">-</text><text class="breeze-setup-synchronize-local-mounts-r4" x="36.6" y="190.8" textLength="48.8" clip-path="url(#breeze-setup-synchronize-local-mounts-line-7)">-dry</t [...] +</text><text class="breeze-setup-synchronize-local-mounts-r5" x="0" y="215.2" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-8)">│</text><text class="breeze-setup-synchronize-local-mounts-r4" x="24.4" y="215.2" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-8)">-</text><text class="breeze-setup-synchronize-local-mounts-r4" x="36.6" y="215.2" textLength="61" clip-path="url(#breeze-setup-synchronize-local-mounts-line-8)">-help</te [...] +</text><text class="breeze-setup-synchronize-local-mounts-r5" x="0" y="239.6" textLength="1464" clip-path="url(#breeze-setup-synchronize-local-mounts-line-9)">╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯</text><text class="breeze-setup-synchronize-local-mounts-r1" x="1464" y="239.6" textLength="12.2" clip-path="url(#breeze-setup-synchronize-local-mounts-line-9)"> +</text> + </g> + </g> +</svg> diff --git a/images/breeze/output_setup_synchronize-local-mounts.txt b/images/breeze/output_setup_synchronize-local-mounts.txt new file mode 100644 index 0000000000..9a3305886c --- /dev/null +++ b/images/breeze/output_setup_synchronize-local-mounts.txt @@ -0,0 +1 @@ +252c8ee48ca57e6539064544cbd63e58 diff --git a/scripts/ci/pre_commit/pre_commit_local_yml_mounts.py b/scripts/ci/pre_commit/pre_commit_local_yml_mounts.py index d136b83a31..0c4ed9821a 100755 --- a/scripts/ci/pre_commit/pre_commit_local_yml_mounts.py +++ b/scripts/ci/pre_commit/pre_commit_local_yml_mounts.py @@ -17,44 +17,18 @@ # under the License. from __future__ import annotations -import os +import subprocess import sys from pathlib import Path -if __name__ == "__main__": - os.environ["SKIP_BREEZE_SELF_UPGRADE_CHECK"] = "true" - sys.path.insert(0, str(Path(__file__).parent.resolve())) # make sure common_precommit_utils is imported +sys.path.insert(0, str(Path(__file__).parent.resolve())) +from common_precommit_utils import console, initialize_breeze_precommit - from common_precommit_utils import AIRFLOW_SOURCES_ROOT_PATH # isort: skip +initialize_breeze_precommit(__name__, __file__) - sys.path.insert(0, str(AIRFLOW_SOURCES_ROOT_PATH)) # make sure setup is imported from Airflow - sys.path.insert( - 0, str(AIRFLOW_SOURCES_ROOT_PATH / "dev" / "breeze" / "src") - ) # make sure setup is imported from Airflow - - from airflow_breeze.utils.docker_command_utils import VOLUMES_FOR_SELECTED_MOUNTS - from common_precommit_utils import insert_documentation - - sys.path.append(str(AIRFLOW_SOURCES_ROOT_PATH)) - - MOUNTS_HEADER = ( - " # START automatically generated volumes from " - "VOLUMES_FOR_SELECTED_MOUNTS in docker_command_utils.py" - ) - MOUNTS_FOOTER = ( - " # END automatically generated volumes from " - "VOLUMES_FOR_SELECTED_MOUNTS in docker_command_utils.py" - ) - - local_mount_file_path = AIRFLOW_SOURCES_ROOT_PATH / "scripts" / "ci" / "docker-compose" / "local.yml" - PREFIX = " " - volumes = [] - for src, dest in VOLUMES_FOR_SELECTED_MOUNTS: - volumes.extend( - [ - PREFIX + "- type: bind\n", - PREFIX + f" source: ../../../{src}\n", - PREFIX + f" target: {dest}\n", - ] - ) - insert_documentation(local_mount_file_path, volumes, MOUNTS_HEADER, MOUNTS_FOOTER) +res = subprocess.run( + ["breeze", "setup", "synchronize-local-mounts"], + check=False, +) +if res.returncode != 0: + console.print("\n[red]Error when running local mounts synchronization.\n")
