Skip to content

Commit

Permalink
Update name of file docker-compose.yaml
Browse files Browse the repository at this point in the history
Issue: 365150653
Reviewed-on: #4451
  • Loading branch information
dahlstrom-g committed Nov 19, 2024
1 parent 34382e9 commit 66a0555
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions cobalt/devinfra/kokoro/bin/dind_py/dind_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def push_image(target_image):
utils.exec_cmd(command)


def get_local_image_name(service, compose_file='docker-compose.yml'):
def get_local_image_name(service, compose_file='docker-compose.yaml'):
"""
Parses the docker-compose file to determine the image-name from the
service-name. When the compose-file is used to build the image, it will get
Expand All @@ -108,7 +108,9 @@ def tag_image(src_img, dest_img):
utils.exec_cmd(tag_command)


def run_docker_build(platform, target_image, compose_file='docker-compose.yml'):
def run_docker_build(platform,
target_image,
compose_file='docker-compose.yaml'):
"""
Runs the docker build for the provided platform, and tags the newly built
image with the registry/image/tag arguments. If the build fails, instead it
Expand All @@ -135,7 +137,7 @@ def run_cobalt_build(image_to_run, src_root):
service = _DOCKER_COMPOSE_SERVICE_TARGET
script = os.path.join(src_root, _INTERNAL_KOKORO_BUILD_SCRIPT)
compose_file = os.path.join(src_root,
'cobalt/devinfra/kokoro/docker-compose.yml')
'cobalt/devinfra/kokoro/docker-compose.yaml')
compose_cmd = (f'docker compose -f {compose_file} ' +
f'run -T {service} /bin/bash -c {script}')
utils.exec_cmd(compose_cmd)
2 changes: 1 addition & 1 deletion cobalt/devinfra/kokoro/bin/dind_py/dind_common_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
'docker-build-failure:test')
BROKEN_IMAGE = 'us-central1-docker.pkg.dev/fake-image:fake-tag'

COMPOSE_FILE_PATH = f'{TEST_DIR_PATH}/test-docker-compose.yml'
COMPOSE_FILE_PATH = f'{TEST_DIR_PATH}/test-docker-compose.yaml'


@unittest.skipIf(os.name == 'nt', 'Does not work on Windows')
Expand Down
File renamed without changes.

0 comments on commit 66a0555

Please sign in to comment.