{"id":14008115,"url":"https://github.com/jdevelop/repull","last_synced_at":"2026-01-12T11:24:22.389Z","repository":{"id":47467894,"uuid":"305894990","full_name":"jdevelop/repull","owner":"jdevelop","description":"A tool to restart a Docker container with a newer version of the image","archived":false,"fork":false,"pushed_at":"2021-08-30T16:45:08.000Z","size":52,"stargazers_count":25,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-08-10T11:02:36.880Z","etag":null,"topics":["docker","golang","tools"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jdevelop.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-10-21T03:12:44.000Z","updated_at":"2024-05-07T18:46:42.000Z","dependencies_parsed_at":"2022-09-26T18:41:46.939Z","dependency_job_id":null,"html_url":"https://github.com/jdevelop/repull","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdevelop%2Frepull","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdevelop%2Frepull/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdevelop%2Frepull/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdevelop%2Frepull/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jdevelop","download_url":"https://codeload.github.com/jdevelop/repull/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227410453,"owners_count":17774752,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","golang","tools"],"created_at":"2024-08-10T11:01:14.422Z","updated_at":"2026-01-12T11:24:22.382Z","avatar_url":"https://github.com/jdevelop.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# repull\n\nA tool to restart a Docker container with a newer version of an image used by the container\n---\n\nOften you may need to pull a newer version of an image to re-create an existing container, \nand you don't care much about the checkpoints because the application is stateless.\n\nThe usual way of doing that is to use \n```\ndocker pull repo/app\ndocker kill containerId\ndocker rm containerId \ndocker run --name xyz --link -v ... -p ... etc\n```\n\nThis is quite tedious and requires to remember all the command line options that were used to start the container. \nWith `k8s` or `docker-compose` it is possible to solve that, but for vanilla Docker containers it could be tricky.\n\n`repull` simplifies it to the point of `repull \u003ccontainerid\u003e \u003ccontainername\u003e...`.\n\nIt will\n\n1. iterate over the list of passed container ids or names\n2. fetch the description of the container\n3. identify the image used in the container\n4. lookup the information about the authentication in `~/.docker/config.json`\n5. pull the new version of the image, if available for the current tag.\n6. kill the existing container\n7. remove the existing container\n8. start the new container with the newest image available **preserving all configuration/startup options**\n9. repeat for all images passed in the arguments.\n\n## Install and Run from Github Content Repository\n```\n $ docker run      \\\n   -v /var/run/docker.sock:/var/run/docker.sock  \\\n   -v $HOME/.docker/config.json:/.docker/config.json   \\\n   ghcr.io/jdevelop/repull:latest CONTAINER_NAME1 CONTAINER_NAME2 ... CONTAINER_NAMEN\n```\n\n## Install and Run from Source (requires go)\n```\n$ go install github.com/jdevelop/repull\n$ repull -h\n```\n\n## Usage\n```\n./repull -h\nUsage of ./repull:\n  -t int\n        timeout (seconds) (default 5)\n  -v    verbose\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdevelop%2Frepull","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjdevelop%2Frepull","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdevelop%2Frepull/lists"}