Created
June 21, 2022 14:37
-
-
Save arevindh/ec4628a9dc9630184bb4e1c76472dc36 to your computer and use it in GitHub Desktop.
Install docker compose
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Docker Compose | |
compose_release() { | |
curl --silent "https://api.github.com/repos/docker/compose/releases/latest" | | |
grep -Po '"tag_name": "\K.*?(?=")' | |
} | |
if ! [ -x "$(command -v docker-compose)" ]; then | |
curl -L https://github.com/docker/compose/releases/download/$(compose_release)/docker-compose-$(uname -s)-$(uname -m) \ | |
-o /usr/local/bin/docker-compose && chmod +x /usr/local/bin/docker-compose | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment