Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

How to upgrade docker-compose to latest version

// First, remove the old version:

//STEP- 1
// If installed via apt-get
sudo apt-get remove docker-compose
// If installed via curl
sudo rm /usr/local/bin/docker-compose
//If installed via pip
pip uninstall docker-compose

// STEP-2 GET LATEST VERSION
// curl + grep
VERSION=$(curl --silent https://api.github.com/repos/docker/compose/releases/latest | grep -Po '"tag_name": "K.*d')

// FINAL_STEP Install and make it executeable
DESTINATION=/usr/local/bin/docker-compose
sudo curl -L https://github.com/docker/compose/releases/download/${VERSION}/docker-compose-$(uname -s)-$(uname -m) -o $DESTINATION
sudo chmod 755 $DESTINATION

// for docker-compose 3.9 
// https://docs.docker.com/compose/compose-file/compose-file-v3/#resources
Comment

how to upgrade docker-compose version

First step, remove the existing version

// If installed via apt-get
sudo apt-get remove docker-compose

// If installed via curl
sudo rm /usr/local/bin/docker-compose

// if installed via pip
pip uninstall docker-compose

Second step, Install the new one (check the latest version from here https://docs.docker.com/compose/install/)

sudo curl -L "https://github.com/docker/compose/releases/download/1.29.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose

Third step, make it accessible

sudo chmod +x /usr/local/bin/docker-compose

Fourth, finally check whether version is update

docker-compose --version
Comment

upgrade docker-compose version

$ sudo apt update
$ sudo apt install docker-compose-plugin
$ sudo rm /usr/local/bin/docker-compose
$ echo 'alias docker-compose="docker compose"' >> ~/.bashrc
$ source ~/.bashrc
$ docker-compose version
Comment

docker-compose update

sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
Comment

how to upgrade docker compose version in windows

Invoke-WebRequest "https://github.com/docker/compose/releases/download/v2.10.2/docker-compose-Windows-x86_64.exe" -UseBasicParsing -OutFile $Env:ProgramFilesDockerdocker-compose.exe
Comment

how to upgrade docker compose version in windows

Invoke-WebRequest "https://github.com/docker/compose/releases/download/v2.10.2/docker-compose-Windows-x86_64.exe" -UseBasicParsing -OutFile $Env:ProgramFilesDockerdocker-compose.exe
Comment

how to upgrade docker compose version in windows

Invoke-WebRequest "https://github.com/docker/compose/releases/download/v2.10.2/docker-compose-Windows-x86_64.exe" -UseBasicParsing -OutFile $Env:ProgramFilesDockerdocker-compose.exe
Comment

how to upgrade docker compose version in windows

Invoke-WebRequest "https://github.com/docker/compose/releases/download/v2.10.2/docker-compose-Windows-x86_64.exe" -UseBasicParsing -OutFile $Env:ProgramFilesDockerdocker-compose.exe
Comment

PREVIOUS NEXT
Code Example
Shell :: rpm install google-chrome-stable in cmd 
Shell :: hydra use find password cracker 
Shell :: d3 install 
Shell :: install haskell 
Shell :: configure editor for git 
Shell :: home directory of wsl 
Shell :: change password raspberry pi 
Shell :: how to check jibri version 
Shell :: install react yarn 
Shell :: change user linux 
Shell :: test redis connection 
Shell :: find zombie process PID in linux 
Shell :: node sass generate css 
Shell :: linux settings not opening 
Shell :: git remove files from repo but not locally 
Shell :: git remote commands 
Shell :: git upload folder 
Shell :: bash go to folder 
Shell :: how to config username and email in git 
Shell :: git stash drop 
Shell :: *15856 connect() to unix:/var/run/php/php8.0-fpm.sock failed (11: Resource temporarily unavailable) 
Shell :: cut tab linux 
Shell :: Can I deploy a branch in netlify 
Shell :: mount cifs ubuntu 
Shell :: ERROR: Could not build wheels for backports.zoneinfo, which is required to install pyproject.toml-based projects 
Shell :: Run Google Colab With Local Files 
Shell :: react icons installation through npm 
Shell :: how to uninstall program on ubuntu 
Shell :: Cask adoptopenjdk8 exists in multiple taps: 
Shell :: remove all folder except one linux 
ADD CONTENT
Topic
Content
Source link
Name
8+4 =