Skip to content
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

Errors out instead of trying to workaround buggy docker-compose v2 #16989

Merged
merged 1 commit into from
Jul 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions breeze
Original file line number Diff line number Diff line change
Expand Up @@ -590,6 +590,22 @@ function breeze::prepare_command_file() {
local compose_file="${3}"
cat <<EOF >"${file}"
#!/usr/bin/env bash
docker_compose_version=\$(docker-compose --version)
if [[ \${docker_compose_version} =~ .*version\ 2.* ]]; then
echo
echo "${COLOR_RED}Docker Compose Beta version 2has bug that prevents breeze from running.${COLOR_RESET}"
echo "${COLOR_RED}You have: \${docker_compose_version}.${COLOR_RESET}"
echo
echo "${COLOR_YELLOW}Please switch to stable version via Docker Desktop -> Experimental or by running:${COLOR_RESET}"
echo
echo "${COLOR_CYAN}docker-compose disable-v2${COLOR_RESET}"
echo
echo "${COLOR_YELLOW}Also please upvote https://github.com/docker/compose-cli/issues/1917${COLOR_RESET}"
echo
echo "${COLOR_RED}Exiting until you disable v2 version.${COLOR_RESET}"
exit 1
fi

if [[ \${VERBOSE} == "true" ]]; then
echo
echo "Executing script:"
Expand Down
70 changes: 0 additions & 70 deletions scripts/ci/docker-compose/_docker_compose.env

This file was deleted.

2 changes: 1 addition & 1 deletion scripts/ci/docker-compose/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ services:
- KUBECONFIG=/files/.kube/config
- HOST_HOME=${HOME}
env_file:
- _docker_compose.env
- _docker.env
volumes:
# Pass docker to inside of the container so that Kind and Moto tests can use it.
- /var/run/docker.sock:/var/run/docker.sock
Expand Down