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

Add an url for latest version for easy Linux upgrade #4014

Closed
knutole opened this issue Oct 6, 2016 · 6 comments
Closed

Add an url for latest version for easy Linux upgrade #4014

knutole opened this issue Oct 6, 2016 · 6 comments

Comments

@knutole
Copy link

knutole commented Oct 6, 2016

I'd like to use a script to automatically upgrade docker-compose regularly. Currently, I can't find a static url with latest tag, and need to manually edit the 1.8.0 tag.

curl -L https://github.com/docker/compose/releases/download/1.8.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose

Could there be made available a latest tag for this purpose?

@knutole
Copy link
Author

knutole commented Oct 6, 2016

bash workaround:

#!/bin/bash

# get latest version
LATEST=$(curl -Ls -o /dev/null -w %{url_effective} https://github.com/docker/compose/releases/latest)
VERSION=$(echo $LATEST | sed 's:.*/::')

echo Updating Docker Compose to $VERSION

# download
curl -L https://github.com/docker/compose/releases/download/$VERSION/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker-compose version

@aude
Copy link

aude commented Apr 3, 2019

There are repos for Ubuntu/Debian at https://download.docker.com/linux/....

Could it be an idea to create an up-to-date docker-compose package there, in the same way that there is an up-to-date docker-ce package there?

EDIT: This idea is a duplicate of #2235.

@stale
Copy link

stale bot commented Oct 9, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Oct 9, 2019
@aude
Copy link

aude commented Oct 10, 2019

@knutole, it's now possible. I don't think it was previously.

This works:

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

@stale
Copy link

stale bot commented Oct 10, 2019

This issue has been automatically marked as not stale anymore due to the recent activity.

@stale stale bot removed the stale label Oct 10, 2019
@glours glours closed this as completed Oct 10, 2019
@glours
Copy link
Contributor

glours commented Oct 10, 2019

@aude solution works well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants